> Ok, when the olc saves the file (I use iedit/redit) it leaves those damn > annoying M's at the end of any line with a CR in it. ANyone know a way to > take those damn things out? Or a function they made to lose the CR's? > > Hades I know what you mean, and this is my solution. If I'm not mistaking there is a small error in it that when the first line of the string passed to the function is empty (that is '\r\n') is doesn't change the first '\r\n', that's all. Probably just change the place of the ++ and it'll work fine... char * remove_cm (char *arg) { char *counter = arg; if (!arg) return NULL; sprintf (buf, "%c", *arg); while (*(++counter)) if (*counter != '\r') sprintf (buf, "%s%c", buf, *counter); return buf; } Remko ------------------------------------------------------* Remko M. Wiersma Student Computer Science at the University of Twente e-mail: ia_remko@cs.utwente.nl or WWW: http://wwwbeno.cs.utwente.nl/~ia_remko (but it's OLD!) *----------------------------------------------
This archive was generated by hypermail 2b30 : 12/18/00 PST