Appending eventual strerror() to event message line rather than to new line

master
Thomas Schmitt 12 years ago
parent 5e8c60713a
commit 6ab8ffc137
  1. 21
      xorriso/text_io.c
  2. 2
      xorriso/xorriso_timestamp.h

@ -359,7 +359,7 @@ int Xorriso_read_lines(struct XorrisO *xorriso, FILE *fp, int *linecount,
linept= line;
base_length= 0;
while(1) {
fgot= Sfile_fgets_n(linept, SfileadrL - base_length + 1, fp,
fgot= Sfile_fgets_n(linept, SfileadrL - base_length - 1, fp,
!!(flag & (1 | 8)));
if(fgot == NULL) {
if(ferror(fp))
@ -938,12 +938,27 @@ int Xorriso_msgs_submit(struct XorrisO *xorriso,
else
xorriso->info_text[li+lt]= '\n';
xorriso->info_text[li+lt+1]= 0;
#ifdef NIX
/* <<< */
Xorriso_info(xorriso,4|(flag&3));
if(os_errno>0) {
sprintf(xorriso->info_text, "%ssys : %s\n",
pfx_list[(flag>>2)&15], strerror(os_errno));
sprintf(xorriso->info_text, "%s%s : %s\n",
pfx_list[(flag>>2)&15], sev_text, strerror(os_errno));
Xorriso_info(xorriso,4|(flag&3));
}
#else
if(os_errno>0) {
sprintf(xorriso->info_text + strlen(xorriso->info_text) - 1,
" : %s\n", strerror(os_errno));
}
Xorriso_info(xorriso,4|(flag&3));
#endif
return(1);
}

@ -1 +1 @@
#define Xorriso_timestamP "2010.06.25.102140"
#define Xorriso_timestamP "2010.06.25.174329"

Loading…
Cancel
Save