The char array 'format' sometimes get 10 characters and when strcpy is done on it, strcpy tries to add a '/0' to it beyond the capacity. Not sure why, but, the const char *ch gets bad address. Anyway, format should be atleast 11 chars to accommodate strings like "%.34s\n%42s" and a terminating '\0'.
The char array 'format' sometimes get 10 characters and when
strcpy is done on it, strcpy tries to add a '/0' to it beyond
the capacity. Not sure why, but, the const char *ch gets bad
address. Anyway, format should be atleast 11 chars to accommodate
strings like "%.34s\n%42s" and a terminating '\0'.

GerHobbelt/POPT,GerHobbelt/POPT,flatzo/popt,devzero2000/POPT,flatzo/popt,devzero2000/POPT,GerHobbelt/POPT,devzero2000/POPT