Package: glibc-doc Version: Man page says, perror() will print the string, a colon, a blank and then some helpful error message: -----| man 3 perror |----- The argument string s is printed first, then a colon and a blank, then the message and a new-line. /-----| man 3 perror |-----
However, the colon is only printed if there is a non-empty string to print before the error message: [EMAIL PROTECTED]:/home/jbglaw] $> cat test.c #include <stdio.h> int main(int argc, char argv[]) { perror(NULL); perror(""); perror("some real text"); exit(0); } [EMAIL PROTECTED]:/home/jbglaw] $> gcc -o test test.c [EMAIL PROTECTED]:/home/jbglaw] $> ./test Success Success some real text: Success [EMAIL PROTECTED]:/home/jbglaw] $> Even if it makes some sense to omit the colon in the first two lines, I think perror should behave just as the man page states. If someone wants to access the pure error messages, he just may use sys_errlist[]. MfG, JBG -- Fehler eingestehen, Größe zeigen: Nehmt die Rechtschreibreform zurück!!! keyID=0x8399E1BB fingerprint=250D 3BCF 7127 0D8C A444 A961 1DBD 5E75 8399 E1BB
pgpfwib2wksPW.pgp
Description: PGP signature