String Processing Problem

This is a discussion on String Processing Problem within the C Programming forums, part of the General Programming Boards category; I am trying to read in a text file, that contains multiple strings per record. Two of those strings have ...

String Processing Problem

I am trying to read in a text file, that contains multiple strings per record. Two of those strings have embedded blanks. I am trying to read in the string with fgets, and then split the strings out to separate char strings.
I have succeeded in doing so with the following code, however, the field "desc" is coming up blanks. Not sure why .... any ideas?

printf("\nPlease enter the drive being used for input (e.g. a) and press enter.\n");
gets(drive1);
printf("\nPlease enter the name of the input file (e.g. input.dat) and press enter.\n");
gets(in_file_name);
printf("\n**************************************** ****************************************\n");

printf("\nPlease enter the drive being used for output (e.g. a) and press enter.\n");
gets(drive2);
printf("\nPlease enter the name of the output file (e.g. output.dat) and press enter.\n");
gets(output_file_name);