]> sourceware.org Git - newlib-cygwin.git/commitdiff
cygserver: Only print basename of source in debug output to raise readability
authorCorinna Vinschen <corinna@vinschen.de>
Fri, 24 Mar 2017 15:12:52 +0000 (16:12 +0100)
committerCorinna Vinschen <corinna@vinschen.de>
Fri, 24 Mar 2017 15:12:52 +0000 (16:12 +0100)
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
winsup/cygserver/bsd_log.cc

index 2ab3526658898447427c196bfb986f2d3b6f86aa..7c6dcb64539db4ca4499172e5403f20dcb96ca65 100644 (file)
@@ -63,7 +63,8 @@ _vlog (const char *file, int line, int level,
     return;
   pos = stpcpy (buf, "cygserver: ");
   if (file && log_debug == TUN_TRUE)
-    pos += snprintf (pos, 16384 - (pos - buf), "%s, line %d: ", file, line);
+    pos += snprintf (pos, 16384 - (pos - buf), "%s, line %d: ",
+                    basename ((char *) file), line);
   vsnprintf (pos, 16384 - (pos - buf), fmt, ap);
   if (log_syslog == TUN_TRUE && level != LOG_DEBUG)
     syslog (level, buf);
This page took 0.028415 seconds and 5 git commands to generate.