|
-
June 1st, 1999, 06:44 PM
#1
trailing characters on newly initialized character arrays
So I'm doing some file I/O and when i initialize a character array of a given size, a bunch of nonsense characters (like ýýýýÝÝÝÝÝÝÝÝÝÝÝA) is appended IN ADDITION to all of the characters i want. Do you think it has something to do w/ the placement of the array in memory? I'm first declaring the pointer, then assigning a size a couple lines later:
char *InString;
InString = new char[FileLength];
where FileLength is an integer. It's really weird, and i've verified it w/ the debugger. Immediately when it is initialized it is given "FileLength" spaces, PLUS a few more for the nonsense characters. Any help would be GREATLY appreciated.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|