]> ruderich.org/simon Gitweb - coloredstderr/coloredstderr.git/blobdiff - tests/example.c
Hook perror(3).
[coloredstderr/coloredstderr.git] / tests / example.c
index 20f731000b936b91ce276bbe9c4e1608c4e173b4..c615211c11872600f005cd5cc3ecac98be3acc6c 100644 (file)
@@ -28,6 +28,9 @@ int main(int argc, char **argv) {
     printf("write to stdout\n");
     fflush(stdout);
 
+    errno = 0;
+    perror("error!");
+
     write(STDERR_FILENO, "write to stderr 2", 17);
     write(STDOUT_FILENO, "write to stdout 2", 17);