18 CRLFPos = strstr(Text,
"\r\n");
19 LFPos = strchr(Text,
'\n');
21 if(CRLFPos == NULL && LFPos == NULL)
26 else if((CRLFPos == NULL) || (LFPos < CRLFPos))
28 strncpy(Line, Text, LFPos - Text);
29 strcpy(Text, LFPos + 1);
30 Line[LFPos - Text] =
'\0';
34 strncpy(Line, Text, CRLFPos - Text);
35 strcpy(Text, CRLFPos + 2);
36 Line[CRLFPos - Text] =
'\0';