Hi all:

I am using auto_ptr for ordinary pointers with no problem but i have a doubt about using it with arrays.

I have an auto_ptr<char>, but what I assign to is a char[] instead of an unique char.
If i use new, i must use delete for deletion, but if I use new[], i must use delete[], but here is auto_ptr the responsible of doing the delete. Wil the auto_ptr do the appropiate delete (normal or [])

If the answer is no, do you have another alternative for guarantee deletion of array.

NOTE: I cannot use vector<char> nor any other container. It must be a char array due to the API i use.

Thanks in advance