summaryrefslogtreecommitdiff
path: root/netkit-tftp
diff options
context:
space:
mode:
authorChris Larson <clarson@kergoth.com>2004-11-25 10:19:50 +0000
committerChris Larson <clarson@kergoth.com>2004-11-25 10:19:50 +0000
commit119b59cd0df00269bfe51d906657193217b8c884 (patch)
treebe4bc7f812a9df2c6b3f17e6c3cc9bfafad07253 /netkit-tftp
parentc985a77fad25302d576fbcf92149c983887bc0b9 (diff)
Remove the EOLN_NATIVE flag from a ton of files (patches & the like for which line ending conversions can break things).
BKrev: 41a5b1c6eA2OPeQrDQEgEwAmKXvQJg
Diffstat (limited to 'netkit-tftp')
-rw-r--r--netkit-tftp/netkit-tftp-0.17/mconfig.patch20
-rw-r--r--netkit-tftp/netkit-tftp-0.17/pack_tftphdr.patch52
-rw-r--r--netkit-tftp/netkit-tftp-0.17/tftpd_add_debug.patch28
3 files changed, 100 insertions, 0 deletions
diff --git a/netkit-tftp/netkit-tftp-0.17/mconfig.patch b/netkit-tftp/netkit-tftp-0.17/mconfig.patch
index e69de29bb2..26f2f2b6b6 100644
--- a/netkit-tftp/netkit-tftp-0.17/mconfig.patch
+++ b/netkit-tftp/netkit-tftp-0.17/mconfig.patch
@@ -0,0 +1,20 @@
+diff -urNd netkit-base-0.17/MCONFIG netkit-base-0.17-new/MCONFIG
+--- netkit-base-0.17/MCONFIG 1969-12-31 18:00:00.000000000 -0600
++++ netkit-base-0.17-new/MCONFIG 2002-10-12 13:33:16.000000000 -0500
+@@ -0,0 +1,16 @@
++BINDIR=/usr/bin
++SBINDIR=/usr/sbin
++MANDIR=/usr/man
++ROOTBINDIR=/bin
++BINMODE=755
++DAEMONMODE=755
++MANMODE=644
++SUIDMODE=4755
++PREFIX=/usr
++EXECPREFIX=/usr
++ROOTPREFIX=
++INSTALLROOT=
++CC=arm-linux-gcc
++CFLAGS=-I/usr/src/coding/projects/userspace/buildroot/output/staging/usr/include -O2 -Wall -W -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline
++LDFLAGS=
++LIBS=
diff --git a/netkit-tftp/netkit-tftp-0.17/pack_tftphdr.patch b/netkit-tftp/netkit-tftp-0.17/pack_tftphdr.patch
index e69de29bb2..ea0fc8663f 100644
--- a/netkit-tftp/netkit-tftp-0.17/pack_tftphdr.patch
+++ b/netkit-tftp/netkit-tftp-0.17/pack_tftphdr.patch
@@ -0,0 +1,52 @@
+
+#
+# Patch managed by http://www.holgerschurig.de/patcher.html
+#
+
+--- netkit-tftp-0.17/include/arpa/tftp.h~pack_tftphdr.patch
++++ netkit-tftp-0.17/include/arpa/tftp.h
+@@ -10,10 +10,6 @@
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+- * 3. All advertising materials mentioning features or use of this software
+- * must display the following acknowledgement:
+- * This product includes software developed by the University of
+- * California, Berkeley and its contributors.
+ * 4. Neither the name of the University nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+@@ -30,10 +26,7 @@
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+- * From: @(#)tftp.h 8.1 (Berkeley) 6/2/93
+- * $Id$
+- *
+- * (Fixed for netkit to have well-defined field sizes)
++ * @(#)tftp.h 8.1 (Berkeley) 6/2/93
+ */
+
+ #ifndef _ARPA_TFTP_H
+@@ -54,14 +47,14 @@
+ #define ERROR 05 /* error code */
+
+ struct tftphdr {
+- u_int16_t th_opcode; /* packet type */
++ short th_opcode; /* packet type */
+ union {
+- u_int16_t tu_block; /* block # */
+- u_int16_t tu_code; /* error code */
+- char tu_stuff[1]; /* request packet stuff */
+- } th_u;
+- char th_data[1]; /* data or error string */
+-};
++ unsigned short tu_block; /* block # */
++ short tu_code; /* error code */
++ char tu_stuff[1]; /* request packet stuff */
++ } __attribute__ ((__packed__)) th_u;
++ char th_data[1]; /* data or error string */
++} __attribute__ ((__packed__));
+
+ #define th_block th_u.tu_block
+ #define th_code th_u.tu_code
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