aboutsummaryrefslogtreecommitdiff
path: root/net/ztelnet/files/patch-av
diff options
context:
space:
mode:
Diffstat (limited to 'net/ztelnet/files/patch-av')
-rw-r--r--net/ztelnet/files/patch-av160
1 files changed, 129 insertions, 31 deletions
diff --git a/net/ztelnet/files/patch-av b/net/ztelnet/files/patch-av
index 71541041fce0..a2c75dcd19eb 100644
--- a/net/ztelnet/files/patch-av
+++ b/net/ztelnet/files/patch-av
@@ -1,32 +1,130 @@
-diff -uNr ../ztelnet/zmodem/sz.h ./zmodem/sz.h
---- ../ztelnet/zmodem/sz.h Mon Apr 24 13:37:47 1995
-+++ ./zmodem/sz.h Thu Jan 1 00:00:00 1970
-@@ -1,28 +0,0 @@
--#ifndef STATIC
--#define STATIC static
--#endif
+diff -uNr --exclude=*.orig work.old/ztelnet/zmodem/sz.c work/ztelnet/zmodem/sz.c
+--- work.old/ztelnet/zmodem/sz.c Mon Apr 24 23:28:58 1995
++++ work/ztelnet/zmodem/sz.c Tue Jun 20 22:58:34 2000
+@@ -1,3 +1,8 @@
++/*-----Apended by yongari -----*/
++#define MD 2
++#define V7
++#define strchr index
++/*----------------------------*/
+ #define STATIC static
+ #define VERSION "3.25 2-11-95"
+ #define PUBDIR "/usr/spool/uucppublic"
+@@ -57,7 +62,10 @@
+
+ STATIC char *Copyrsz = "Copyright 1993 Omen Technology Inc All Rights Reserved";
+
+-STATIC char *substr(), *getenv();
++/* Removed by yongari */
++/* STATIC char *substr(), *getenv(); */
++STATIC char *substr();
++char *getenv(const char *name);
+
+ #define LOGFILE "/tmp/szlog"
+ #define LOGFILE2 "szlog"
+@@ -95,6 +103,26 @@
+
+ #define HOWMANY 250
+
++/*------Appended by yongari to shut up compiler------*/
++STATIC wcsend();
++STATIC wcs();
++STATIC wctxpn();
++STATIC getnak();
++STATIC wctx();
++STATIC wcputsec();
++STATIC filbuf();
++STATIC usage();
++STATIC getzrxinit();
++STATIC sendzsinit();
++STATIC zsendfile();
++STATIC zsendfdata();
++STATIC getinsync();
++STATIC zsendcmd();
++STATIC chkinvok();
++STATIC countem();
++STATIC init_sz();
++/*-----------------------------------------------------*/
++
+ STATIC int Zmodem=0; /* ZMODEM protocol requested by receiver */
+ unsigned Baudrate = 19200; /* Default, set by first mode() call */
+ STATIC unsigned Effbaud = 19200;
+@@ -108,8 +136,7 @@
+ #include "rbsb.c" /* most of the system dependent stuff here */
+
+ #include "crctab.c"
+-/* PMS */
+-#include "sz.h"
++
+ STATIC int Filesleft;
+ STATIC unsigned long Totalleft;
+
+@@ -176,7 +203,9 @@
+ STATIC unsigned long Lastsync; /* Last offset to which we got a ZRPOS */
+ STATIC int Beenhereb4; /* How many times we've been ZRPOS'd here */
+ STATIC int Ksendstr; /* 1= Send esc-?-3-4-l to remote kermit */
+-STATIC char *ksendbuf = "\033[?34l";
++/*-----Modified by yongri-----------*/
++/* STATIC char *ksendbuf = "\033[?34l"; */
++STATIC char ksendbuf[80];
+
+ /*STATIC jmp_buf tohere; /* For the interrupt on RX timeout */
+ STATIC jmp_buf intrjmp; /* For the interrupt on RX CAN */
+@@ -225,6 +254,7 @@
+
+ #include "zm.c"
+ #include "zmr.c"
++
+ sz(argc, argv)
+ char *argv[];
+ {
+@@ -243,7 +273,6 @@
+ Znulls = atoi(cp);
+ if ((cp=getenv("SHELL")) && (substr(cp, "rsh") || substr(cp, "rksh")))
+ Restricted=TRUE;
-
--STATIC void bibi(int);
--STATIC void onintr(int);
--int sz(int argc, char *argv[]);
--STATIC void saybibi(void);
--STATIC wcsend(int argc, char *argp[]);
--STATIC wcs(char* oname);
--STATIC wctxpn(char *name);
--STATIC getnak(void);
--STATIC wctx(unsigned long flen);
--STATIC wcputsec(char* buf, int sectnum, int cseclen);
--STATIC filbuf(register char *buf, int count);
--STATIC zfilbuf(void);
--STATIC fooseek(FILE *fptr, unsigned long pos, int whence);
--STATIC char *substr(register char *s, register char *t);
--STATIC usage(void);
--STATIC getzrxinit(void);
--STATIC sendzsinit(void);
--STATIC zsendfile(char *buf, int blen);
--STATIC zsendfdata(void);
--STATIC getinsync(int flag);
--STATIC zsendcmd(char *buf, int blen);
--STATIC chkinvok(char *s);
--STATIC countem(int argc, register char **argv);
--STATIC init_sz(void);
+ chkinvok(argv[0]);
+
+ Rxtimeout = 600;
+@@ -428,17 +457,20 @@
+ if(errcnt || Exitcode)
+ Exit(1);
+
++#define sleep(x)
+ #ifndef REGISTERED
+ /* Removing or disabling this code without registering is theft */
+ if (!Usevhdrs) {
+ printf("\n\n\nPlease read the License Agreement in sz.doc\n");
+ fflush(stdout);
++ /* sleep(10); */
+ sleep(10);
+ }
+ #endif
+ Exit(0);
+ /*NOTREACHED*/
+ }
++#undef sleep
+
+ /* Say "bibi" to the receiver, try to do it cleanly */
+ STATIC void
+@@ -949,8 +981,7 @@
+ fprintf(stderr,"\nCopyright 1993 Omen Technology INC All Rights Reserved\n");
+ fprintf(stderr,
+ "See sz.doc for option descriptions and licensing information.\n\n");
+- fprintf(stderr,"Ported into telnet by Heo, Junhyeok, 1994.3.28\n");
+- fprintf(stderr,"Linux porting by Park Myeong Seok, 1995.4.23\n");
++ fprintf(stderr,"\nPorted into telnet by Heo, junhyeok 1994.3.28\n");
+ Exit(3);
+ }
+
+@@ -1608,9 +1639,7 @@
+ Lastsync=0;
+ Beenhereb4=0;
+ Ksendstr=0;
+-/* By PMS
+- strcpy(ksendbuf,"\033[?34l");
+-*/
++ strcpy(ksendbuf,"\033[?341l");
+ Zctlesc=0;
+ Nozmodem=0;
+ Zrwindow=1400;