summaryrefslogtreecommitdiff
path: root/netkit-tftp/netkit-tftp-0.17/tftpd_add_debug.patch
diff options
context:
space:
mode:
Diffstat (limited to 'netkit-tftp/netkit-tftp-0.17/tftpd_add_debug.patch')
-rw-r--r--netkit-tftp/netkit-tftp-0.17/tftpd_add_debug.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/netkit-tftp/netkit-tftp-0.17/tftpd_add_debug.patch b/netkit-tftp/netkit-tftp-0.17/tftpd_add_debug.patch
index e69de29bb2..f7dfd58ed4 100644
--- a/netkit-tftp/netkit-tftp-0.17/tftpd_add_debug.patch
+++ b/netkit-tftp/netkit-tftp-0.17/tftpd_add_debug.patch
@@ -0,0 +1,28 @@
+
+#
+# Patch managed by http://www.holgerschurig.de/patcher.html
+#
+
+--- netkit-tftp-0.17/tftpd/tftpd.c~tftpd_add_debug
++++ netkit-tftp-0.17/tftpd/tftpd.c
+@@ -252,6 +252,8 @@
+ char *filename, *mode = NULL;
+
+ filename = cp = tp->th_stuff;
++ syslog(LOG_NOTICE, "tp->th_opcode=%x, tp = %p, &(tp->th_stuff)=%p, filename=%s", tp->th_opcode,tp, &(tp->th_stuff),filename);
++
+ again:
+ while (cp < buf + size) {
+ if (*cp == '\0')
+@@ -340,8 +342,10 @@
+ return(EACCESS);
+ }
+ }
+- if (stat(filename, &stbuf) < 0)
++ if (stat(filename, &stbuf) < 0) {
++ syslog(LOG_NOTICE, "file %s not found", filename);
+ return (errno == ENOENT ? ENOTFOUND : EACCESS);
++ }
+ #if 0
+ /*
+ * The idea is that symlinks are dangerous. However, a symlink