Message-ID: <39AD6455.DC1FCF30@softhome.net> Date: Wed, 30 Aug 2000 21:45:25 +0200 From: Laurynas Biveinis X-Mailer: Mozilla 4.74 [en] (Win98; U) X-Accept-Language: lt,en MIME-Version: 1.0 To: djgpp-workers AT delorie DOT com CC: mail AT jgreen4 DOT fsnet DOT co DOT uk Subject: Re: Symify fixes References: <226lqssqgqp6i9nk82rvrqhl9aaia029e9 AT 4ax DOT com> <7458-Mon28Aug2000203504+0300-eliz AT is DOT elta DOT co DOT il> <8011-Mon28Aug2000234727+0300-eliz AT is DOT elta DOT co DOT il> <39AD1BF3 DOT 139CB5DB AT softhome DOT net> <9003-Wed30Aug2000195653+0300-eliz AT is DOT elta DOT co DOT il> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp-workers AT delorie DOT com Eli Zaretskii wrote: > It's probably better to use strerror, since you already have an > fprintf. OK, I suggest the following. Note that I've added function attribute stating that bail() never returns to caller. Unfortunately, it forced to add a prototype: static void bail(const char *msg) __attribute__ ((noreturn)); And here is the function: static void bail(const char *msg) { assert(msg); if (errno) fprintf(stderr, "Symify error: %s: %s\n", msg, strerror(errno)); else fprintf(stderr, "Symify error: %s\n", msg); exit(EXIT_FAILURE); } If nobody objects, I commit it with the rest of patches. Laurynas