On line 7 you allocate memory and then on line 8 you immediately discard that memory forever. That memory will stay allocated until the program dies. This is called a memory leak, and preventing memory leaks is a good habit to learn from the beginning.
Is there missing code? I believe there is a missing } in the code that you posted.
I think the addFront, add, and addEnd functions are missing from what you posted.
It would be easier to help you with more of your code present.
Also, I just saw this code current = previous = ptr = NULL;
A better way to write that would be using multiple lines of code. One assignment per line. IMO this line is unnecessary since these are all local variables within the addBetween function.