thanks
thanks
Last edited by Dorky King; 05-30-2007 at 11:21 AM. Reason: problem solved
Well, for one thing...
...you just lost your old header.Code:if (header->next == NULL){ header = (list_type*)malloc(sizeof(list_type));
If you understand what you're doing, you're not learning anything.
Usually means one of the following.Originally Posted by msdn
- You didn't implement the function
- You didn't spell it right, or get the case right ( foo != Foo for example)
- For C++, the parameters don't match.
> new = (list_type *) malloc ( sizeof (list_type) );
See the FAQ on casting (or rather, not casting) malloc in C.
If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
If at first you don't succeed, try writing your phone number on the exam paper.