ckc197.txt
资源名称:cku197.tar.Z [点击查看]
上传用户:dufan58
上传日期:2007-01-05
资源大小:3407k
文件大小:866k
源码类别:
通讯/手机编程
开发平台:
Windows_Unix
- but not pass the start-printer or stop-printer sequences to the printer.
- Changed most UNIX makefile targets from wermit to xermit, to use the new
- select()-based CONNECT module, which has much new stuff in it that ckucon.c
- does not have. In general, I changed every entry that has -DTCPSOCKET to the
- xermit target unless it was really old and I hadn't heard anything about it in
- many years. makefile, 26 Nov 98.
- Added HELP text for recent commands. ckuus2.c, 26 Nov 98.
- If DIAL RETRIES was not set explicitly, then at DIAL time use a retry limit
- based on the local country code. Currently, this is 10 for country code 1
- and 1 for all others. This can be expanded as I get info about other
- countries. ckuus[346].c, 26 Nov 98.
- Added SET CLOSE-ON-DISCONNECT { ON, OFF }. If ON, it means that if we notice
- that a serial connection is disconnected (because CD went off), we close the
- device immediately. This releases it for use by others (e.g. removing the
- lockfile in UNIX). OFF by default, for consistency with previous releases.
- Supporting code needs to be added for K95; it goes in ttchk() -- see example
- in ckutio.c (search for "clsondisc"). ckcmai.c, ckuus[r234].c, ck[uv]tio.c,
- 26 Nov 98.
- #ifdef adjustments to allow building with different features deselected:
- many, many modules. 26 Nov 98. Examples (on SunOS 4.1.3):
- Full: 1155072
- -DNOIKSD 1146880
- -DNOLOGIN: 1138688
- -DNOPUSH 1122304
- -DNOSPL 999424
- -DNOLOCAL: 884736
- -DNOLOCAL -DNOLOGIN 819200
- sunos41mi: 335872
- sunos41m: 212992
- Don't let "close connection" fall through if clsconnx() returns an unexpected
- value. ckuusr.c, 27 Nov 98.
- Added MANUAL command, which in UNIX runs the "man" command, default topic
- "kermit". In VMS it runs the "help" command, default topic "kermit". For K95,
- I wrote code to parse chapter names and then to run SE on:
- file:///<startupdir>/DOCS/manual/kermit95.htm#<chapter>
- but have no way to compile or test, needs fixing. ckuusr.[ch], 29 Nov 98.
- Added a reference to the MANUAL command to the main HELP screen. ckuus2.c,
- 29 Nov 98.
- Changed HANGUP command to also call ttchk(). This way, if the HANGUP command
- forced a serial connection to close (and carrier to drop), this engages the
- SET CLOSE-ON-DISCONNECT code. ckuusr.c, 29 Nov 98.
- Added support for 75/1200 bps split speed for Unixware 7. Untested.
- ckutio.c, 29 Nov 98.
- Added missing sections to ckermit2.txt: SET [ SERVER ] CD-MESSAGE, SET FILE
- PATTERNS AUTO, SET COMMAND AUTODOWNLOAD, LATIN-9, TYPE /PAGE, and RESET, plus
- COPY command improvements. 29-30 Nov 98.
- Fixed 75/1200 support after testing revealed it didn't work. ckutio.c,
- ckuus5.c, 30 Nov 98.
- Built on Red Hat Linux 5.2. Needed -lcrypt added to LIBS. makefile,
- 30 Nov 98.
- Linux version could not access modem signals. Got help from Ted Ts'o and
- Gert Doering, now it works. SHOW COMM shows them, CONNECT mode pops back to
- command prompt automatically when carrier drops, etc. ckutio.c, 1 Dec 98.
- Built Linux C-Kermit with egcs 1.0.3 on Red Hat 5.2. Added linuxegcs makefile
- entry. makefile, 1 Dec 98.
- Also checked linuxs entry (static linking) -- works, makes a 2.2MB executable
- (compared to 914K with dynamic linking).
- Made FAST the default for UNIX and VMS (it already was the default in K95);
- let's see who hollers. ckcmai.c, ckcker.h, ckuus[5h].c, 1 Dec 98.
- Added SOCKS5 support from Ric Anderson. ckcdeb.h, ckcnet.[ch], ckuus5.c,
- 1 Dec 98.
- Fixed the MANUAL command to account for NOPUSH/nopush. ckuus[r2].c, 1 Dec 98.
- Supplied missing RMKDIR command. ckuusr.c, 1 Dec 98.
- Verified IKSD on Red Hat 5.2 Linux 2.1.125. All is OK except, like SunOS,
- it has the syslog-vs-chroot bug. See notes from 30 Aug 98.
- Moved annoying error messages from REDIRECT parsing to after confirmation, so
- we can use command recall. This should also be done for any other commands
- that issue error messages and fail in mid-parse for non-syntactic reasons.
- ckuusr.c, 1 Dec 98.
- New & improved HP-UX makefile entries from Peter Eichhorn. 2 Dec 98.
- Confirmation from Piet Vloet at Siemens Austria that 8 bits + parity work OK
- on Solaris. 2 Dec 98.
- kermit -y filename was broken, more fallout from the "call prescan() twice"
- business (see notes from 22 Aug), this time because of the argument that was
- added that made it skip some things. I just put it all back to the way it was
- prior to 19 July and it seems to work OK (the notes don't shed any light, but
- probably the changes were made for some reason specific to K95, so proper
- prescan() operation should be rechecked there). ckuus4.c, 2 Dec 98.
- Added a bunch of missing commas separating help-text lines. ckuus2.c,
- 2 Dec 98.
- Removed now-inappropriate #ifdef NETCONN from extern int ttnproto in ckudia.c,
- 2 Dec 98.
- Added -DNOGETUSERSHELL to all HP-UX entries prior to 8.00. makefile, 2 Dec 98.
- SCO OSR5, and therefore probably all earlier versions, get unresolved
- references to "std_syslog" and "openlog" at link time. Builds OK only with
- -DNOSYSLOG. Added -DNOGETUSERSHELL and -DNOSYSLOG to SCO OSR5 entries, and
- -DNOIKSD to all the other SCO entries (except Unixware). makefile, 2 Dec 98.
- Added appropriate #includes for select() to ckucns.c, needed at least for QNX.
- ckucns.c, 2 Dec 98.
- Built on dozens of platforms, made numerous adjustments to #ifdefs and
- declarations. 2 Dec 98.
- Added -DNOIKSD to HP-UX 5.x entry. Makefile, 3 Dec 98.
- Fixed a bug in which "run blahfxxx" (RUN any-string-with-f-in-it) would
- hang. The problem turned out to be that the RUN command parser always
- returned -1 if cmtxt failed, rather than returning cmtxt's return code.
- ckuusr.c, 3 Dec 98.
- Fixed a longstanding bug in the BSDI version, in which incoming file dates
- were set in GMT rather than local time. It seems in 4.4BSD, localtime() does
- not return the local time, but rather Zero Meridian (Zulu) time (GMT), and
- must be adjusted by the tm_gmtoff value. ckcdeb.h, ckufio.c, 3 Dec 98.
- It turns out the same bug also affected FreeBSD, so I'm assuming it also
- applies to all other 4.4BSD derivatives, and so made the previous change be
- #ifdef BSD44. Tested OK in FreeBSD 2.2.7 and BSDI 3.1. ckufio.c, 3 Dec 98.
- After getting "man" to work on SCO 3.2v5.0.5, I discovered that -lsocket is
- required there to make syslog() work. Added -DSYSLOG to the sco32v5*net*
- entries, which already were linking with libsocket. Added a separate set of
- entries for SCO 3.2v5.05. ckcdeb.h, ckuver.h, makefile, 3 Dec 98.
- Noticed that the SCO OSR5 version was sending uppercase filenames. Started to
- work on tracking it down, but now, just when it gets to the filename, it
- crashes in the malloc() that is called from sfile(). There does not appear to
- be anything wrong with this code, and the same code works fine on dozens of
- other platforms. malloc() is being passed an integer whose value is 1024.
- Compiling with gcc rather than cc fixes the problem. Not very satisfying,
- though... Keeping at it, I found that if I reworked the offending bit of code
- and rebuilt with cc, the problem moved to another unrelated bit. Finally I
- tracked it down to a non-ANSI prototype for getcwd() in zgtdir(). Commenting
- it out fixed everything. So what other little time bombs are lurking
- throughout the code? (Lines that were perfectly harmless for years and years
- can suddenly become fatal...) ckufio.c, 3 Dec 98.
- The problem with uppercase filenames comes from using "send /bin", and in fact
- happens everywhere, not just on SCO. It's because "send /bin" sets transfer
- mode to manual and file type to binary, to force a binary transfer no matter
- what. But manual transfer mode means we don't automatically switch to literal
- filenames when sending UNIX to UNIX. Phooey. This was fixed as follows:
- previously, when we compared system types, we did so only if xfermode == auto.
- If they match, we set the transfer mode to binary and file names literal.
- Now we compare system types not only if xfermode == auto, but also if the
- global (saved) g_xfermode == auto. In this case, we set file names to literal
- if they match, but we set the transfer mode to binary only if xfermode == auto,
- i.e. if the *current* transfer mode is auto. ckcfns.c, 3 Dec 98.
- When using new C-Kermit on VMS to make a Telnet connection, it says: "tn_push
- has not been defined. data loss!!!!" -- kinda scary... Copied the le_blah()
- code from UNIX to VMS, and enabled the le_puts() call for VMS in tn_push().
- But it doesn't work very well -- there is a long pause at the beginning of the
- connection, and then 10-20 lines of junk come out (but after that it's normal).
- Apparently this much more difficult than I thought, mainly because in UNIX,
- the same functions (ttinc(), ttxin(), etc) are used for both serial and
- network connections, whereas in VMS, we call netinc(), netxin(), etc, for
- network connections. Put everything back the way it was. We get the scary
- message, and have to hit return before seeing a login: prompt, but after that
- all is OK. To be cont'd...
- (Next day...) It's worse than I thought. The telnet local-echo buffer
- business breaks the INPUT command on Telnet connections, even for the UNIX
- version.
- Fixed long lines in ckuath.c, ckuat2.c, and ckusig.c. 4 Dec 98.
- Fixes from Jeff for INPUT vs local-echo buffer, plus a keyword-table size
- error. ckcnet.c, ckuus7.c, 8 Dec 98.
- Changed hardwired references to uid_t and gid_t in the new authentication code
- to UID_T and GID_T, which are portably defined in ckcdeb.h, to fix ckufio.c
- compilation failure on HP-UX 6.5. Also needed to add -DNOSYSLOG and -DNOSELECT
- (because ckcdeb.h defines SELECT for all HPUX's, but it's not there prior to
- 7.0 unless TCP/IP is installed). makefile, ckufio.c, 8 Dec 98.
- Fixed UNIXLOGIN macro to allow for the possibility that a login: prompt might
- not appear. Fixed NET macro to include "set login user" to disable sending
- of user ID in Telnet negotiations. ckermit.ini, 8 Dec 98.
- All-day project: Got common source and makefile to build cleanly on both
- Red Hat 5.2 Linux (glibc) and Slackware 3.5.0 (libc). Of course the results
- are still not binary compatible. How could they be? makefile, ckutio.c,
- 8 Dec 98.
- Removed all gratuitous prototypes for getcwd() from zgtdir(). Let's see
- who complains. ckufio.c, 8 Dec 98.
- Almost everybody, of course. Started the long, slow process of adding back
- prototypes for those platforms that don't provide them: HP-UX 6.5, Motorola
- SV68, etc. This was handled in various ways -- including <unistd.h> in builds
- where it wasn't included before, adding a new DCLGETCWD symbol to CFLAGS of
- selected builds, and so on. zgtdir() now has real _PROTOTYP's for getcwd()
- rather than the non-ANSI hardwired ones, and all are in #ifdef
- DCLGETCWD..#endif. But since getcwd() prototypes involve size_t's, this too
- needed an escape clause, so I made them all SIZE_T, which is defined by
- default to be size_t in ckcdeb.h, but can be overridden on the command line
- with -DSIZE_T=int or whatever. makefile, ckufio.c, ckcdeb.h, 9 Dec 98.
- Trying to get tn_push() & friends to work in VMS (cont'd from last week...)
- Moved all the code that I had added to ckvtio.c to ckcnet.c, since, for
- network connections, all of the ckvtio.c routines call their ckcnet.c cousins
- anyway (ttinc() calls netinc(), etc). The result works ok, except it is stuck
- until the user hits the first key. Killing a process stuck in this way that
- had its debug log on reveals the hangup to be in contti(), which is back in
- the ckvtio.c module I just moved all this code out of... Added a(nother)
- special hack to contti() to account for the local-echo buffer. Arranged
- ckcnet.[ch] so that TTLEBUF selects the external implementation of these
- routines & buffers, and NETLEBUF selects the internal one. Defined TTLEBUF
- for UNIX and NETLEBUF for VMS. ckcnet.[ch], ck[vu]tio.c, 9 Dec 98.
- Defined TTLEBUF for AOS/VS and added the code to ckdtio.c (but, like the
- initial VMS try, it still gets stuck at the very beginning). 9 Dec 98.
- Numerous source-level adjustments for AOS/VS. For example, if a module
- contains "extern int blah;", the link step will fail if blah is not defined
- anywhere, even if it is never used. Many modules. 9 Dec 98.
- SOCKOPT_T adjustments for AIX 4.2 & 4.3. ckcnet.c, 9 Dec 98.
- Changes from Jeff for hardware parity & stop bits for K95, plus other minor
- code adjustments. ckcdeb.h, ckuus[34].c, ckcnet.c, 10 Dec 98.
- From Jeff: When an incoming TCP connection has dropped, don't listen for a
- new one. ckcnet.c, 10 Dec 98.
- More adjustments for AOS/VS. ckdcon.c, ckcpro.w, etc. Now it links without
- multiply defined or undefined symbol errors. 10 Dec 98.
- Fixed the sticking problem in AOS/VS Telnet: there was a vestigial ttflui()
- call in the AOS/VS version of ttpkt(). ckdtio.c, 10 Dec 98.
- Increased compiler memory (-qmaxmem) from 6000 to 8000 for AIX 4.1 builds,
- and to 10000 for AIX 4.2 and 4.3 (but this is still not enough for some
- modules -- no big deal). makefile, 10 Dec 98.
- Adjusted #ifdefs for GETSOCKNAME_T, etc, to allow clean compilation on AIX
- 4.3 & 4.2, since data types for various sockets library function args changed
- between AIX 4.1 and 4.2. ckcnet.c, 10 Dec 98.
- Made SET SPEED command not complain because it's a network connection until
- after confirmation (see note on REDIRECT, 1 Dec 98). ckuus3.c, 10 Dec 98.
- Problem: SET PORT blah, SET MODEM TYPE blah, DIAL blah. Then SET HOST blah.
- Now that we have a network connection, HANGUP still sends the modem hangup
- sequence. It *should* send this sequence if SET MODEM TYPE was given *after*
- SET HOST (see p.126), but not if it was given before. Code looks right --
- setlin() leaves modem type negative upon exit. Well, further testing reveals
- problems go a lot deeper when we switch back & forth between serial and
- network connections -- sometimes lockfiles were left behind, SET SPEED
- commands would fail, etc. The primary cause was the failure of (at least the
- UNIX version of) ttopen() to unset the "it's a network connection" variable
- in all cases when it opened a serial connection. I also made another change,
- namely that mdmhup() should call ttchk() before sending +++ATH0+++ to make
- sure there is still a connection. If there isn't, don't bother. ckutio.c,
- ckudia.c, 10 Dec 98.
- Changes from Jeff for Postscript printer support in K95. ckuusr.h, ckuus3.c,
- 10 Dec 98.
- Added SET DIAL MACRO command. ckuusr.h, ckuus[36].c, ckudia.c, 11 Dec 98.
- Added LOG CONNECTIONS command definitions, parsing, SHOWing. Default
- filename is CX.LOG in user's home directory, overridable by -DCXLOFGILE="xxx"
- on cc command line, or, of course, in the LOG CONNECTIONS command itself.
- ckcker.h, ckcdeb.h, ckuus[r456].c. 11 Dec 98.
- Added code for writing to the connection log. The main idea is to write log
- records as reliably as possible without going into the system-dependent code,
- thus avoiding the necessity to update dozens of modules, many of which can't
- be tested. When a connection is opened, a preliminary log record is written
- to a buffer by the SET LINE or SET HOST code (this happens always, even if a
- log is not open). If it was a serial port, then if a DIAL command is given,
- it overwrites the original record, adding the phone number info. The trick is
- to catch when the connection closes, so we can add the elapsed time to the
- record and write it out to the log (I considered writing separate Open and
- Close records, but people wouldn't like having to match them up). We do this
- in the following places:
- . The HANGUP command.
- . The clsconnx() (close connection) routine.
- . When the CONNECT command returns.
- . When INPUT senses connection loss
- . When the file-transfer protocol senses connection loss.
- . In the program exit sequence as a catch-all.
- We avoid writing duplicate records by punching out the partial buffer after
- writing a record.
- Each record is a line of text; the format is:
- yyyymmdd hh:mm:ss username pid p=v [ p=v [ ... ] ]
- where the timestamp shows when the connection was made; p's are parameters,
- and v's are values:
- T = Connection Type (TCP, SERIAL, DIAL, DECNET, etc).
- H = Originating Host name.
- N = Destination Number or Network host name or address.
- D = Serial connections only: Device name.
- O = Dialed calls only: Originating country code & area code if known.
- E = Elapsed time.
- Many modules, 13 Dec 98.
- Fixed dial macro to (a) also apply to nonportable numbers, and (b) not apply
- when user gives number starting with "=". ckuus6.c, 14 Dec 98.
- Connection logging, cont'd:
- . Flush connection-log writes to disk.
- . Added 2 new syslog levels: DIAL, and All Connections.
- . Added syslogging to dologend() routine.
- . Added a compile-time symbol to force syslogging of desired level.
- . Don't let user set syslogging > 5 (file reading).
- Many modules, 14 Dec 98.
- Added SHOW CONNECTION command to display current session (from partial log
- record in memory), including elapsed time. ckuusr.[ch], 14 Dec 98.
- Added code to force syslogging if built with -DSYSLOGLEVEL=n. This way
- sysadmins can (e.g.) log all dialout calls by all users in syslog. Various
- modules. 14 Dec 98.
- Syslogging is documented in iksd.txt and ckuins.txt. The connection log is
- documented in ckermit2.txt.
- Recent changes to zgtdir() could result in core dumps if called when current
- directory (or "..", etc) is unreadable. Also went from getcwd() back to
- getwd() in SunOS since getcwd() is implemented there via popen() calling the
- shell to run pwd, which is gross and slow, and also prints unwanted messages
- in the aforementioned case. But getwd() is "deprecated" and not recognized by
- POSIX so we avoid it elsewhere. To force its use, add USE_GETWD to CFLAGS.
- ckufio.c, 15 Dec 98.
- Added /COMMAND, /BINARY, and /TEXT switches to TRANSMIT. ckuus[r24].c,
- ckufio.c, 15 Dec 98.
- Made STATISTICS show streaming in window-slots field, like file-transfer
- display does. ckuus4.c, 15 Dec 98.
- Bug: the dial interval, once interrupted by "pressing any key" goes to 0 once
- (as it should) but then stays there for all subsequent redials. Diagnosis:
- conchk() reported the keystroke(), but coninc() was never called to read it.
- Fixed in dodial(), ckuus6.c, 15 Dec 98.
- It seems that on at least one PC somewhere in the world, ATS2=43 causes an
- ERROR response from a Hayes-compatible modem (Dynalink 1456VQH). But this
- command is hardwired into the code for all AT-command-set modems; there is no
- command to disable it. Compensated for this by:
- 1. If ATS2=nn gives an error code, we (a) print the message only if DIAL
- DISPLAY is on (rather than always), and (b) set MODEM HANGUP-METHOD to
- RS-232, since we do not know that we can make the modem escape back.
- 2. SET MODEM ESCAPE-CHARACTER -1 (or any negative number) now disables the
- sending of the ATS2=nn command to the modem, and also sets MODEM
- HANGUP-METHOD to RS-232.
- Note: this is a continuation of related changes from 9 Sep 98. ckuus6.c,
- ckudia.c, 15 Dec 98.
- Researched high serial speed API in AIX 4.2/4.3. Forget it, it's hopeless.
- Documented what appears to be the method for "speed mapping" (which can be
- done outside Kermit) in ckubwr.txt, AIX section. 15 Dec 98.
- New MANUAL command for K95 from Jeff. 16 Dec 98.
- Updated help text of LOG, CLOSE, and other commands. ckuus2.c, 16 Dec 98.
- Updated UNIX man page. ckuker.cpp, 16 Dec 98.
- Changed streaming to work automatically in the majority of cases, without
- requiring the user to enable it. RELIABLE has a new setting, AUTO, which is
- the new default. When RELIABLE is AUTO and the Kermit program that initiated
- the connection requests streaming, which it does by default when STREAMING is
- AUTO (which is also the default) if the connection is reliable (which it
- knows, because it made the connection itself), now the remote Kermit accepts
- without having to be told to SET RELIABLE ON. It also offers always, which
- should do no harm, since the offer won't be accepted if the local Kermit
- doesn't also offer. This concept will need some proving in the field!
- ckcmai.c, ckcfn[s2].c, ckuus[23457].c, ckermit2.txt, 16 Dec 98.
- Added missing RQUERY shortcut for REMOTE QUERY. Also made QUERY a valid
- command -- does what RQUERY does. There's no need for the "R" since there
- is no local QUERY command, nor any need for one. ckuusr.c, 16 Dec 98.
- Discovered that when sending a file to QNX whose name contained any segment
- longer than 48 chars, the open() failed with ENAMETOOLONG. Added code to
- nzrtol() to truncate each path segment longer than MAXNAMLEN (which is defined
- earlier according to time-honored #ifdefs) to MAXNAMLEN bytes. ckufio.c,
- 16 Dec 98.
- Added variables v(hwparity) (hardware parity, if any) and v(serial)
- (8N1, etc). ckuusr.h, ckuus4.c, 16 Dec 98.
- Made SET SERIAL nxx also SET TERM BYTE to n. ckuus3.c, 16 Dec 98.
- Changes from Jeff to speed up Telnet negotiations. ckcnet.c, 17 Dec 98.
- Discovered that DIR command did not expand ~ in UNIX. That's because it was
- calling system() (which uses sh) rather than zshcmd() (which uses the user's
- preferred shell). Fixed in ckuus6.c, 17 Dec 98.
- Discovered that IF EXIST did not expand ~ in UNIX. That's because zchki()
- did not expand tildes. Fixed in ckufio.c, 17 Dec 98.
- Discovered that fdate() did not expand ~ in UNIX. That's because zfcdat()
- did not expand tildes. Fixed in ckufio.c, 17 Dec 98.
- All this made me realize that any ckufio.c routine that accepts a filename
- as an argument should run tilde_expand() on it, and if I did this, I could
- move all kinds of ugly code out of ckucmd.c. But that would be a rather major
- last-minute overhaul, so it's deferred for the next release.
- Back to the UNIX DIR command. If it runs ls, then we can give ls switches,
- etc, but we don't get regular filename parsing or a FAILURE return code if
- no files match. If we run the built-in DIR command, we don't see permissions,
- owner, group, etc, but we do get filename parsing and an appropriate status
- indication. So I separated LS and DIR, which formerly were synonyms. Now LS
- runs ls, and DIR calls the internal DIR command. ckuusr.[ch], ckuus6.c,
- 17 Dec 98.
- Meanwhile, the internal DIR command had all sorts of problems. For example
- "dir x" would list all files whose names started with "x". Also the headings
- and footings were a bit annoying, so I took them out. domydir(), ckuus6.c,
- 17 Dec 98.
- Yesterday's truncate-filename-segments code forgot to null-terminate its
- buffer, so receiving a file that had a shorter name than a previous one
- resulted in junk at the end of the shorter filename. Fixed in nzrtol(),
- ckufio.c, 17 Dec 98.
- Updates to SET PRINTER & other help text, more Telnet updates, and misc
- minor corrections from Jeff. ckcnet.c, ckuus[r2y].c, 17 Dec 98.
- Discovered a bad situation in UNIX fgen(), in which a debug() statement
- would try to print the filename string even when no files were found and
- therefore the state of the string pointer was undefined. Recent code changes
- made this cause core dumps. Fixed in fgen(), ckufio.c, 17 Dec 98.
- Added new system-dependent function: ziperm(filename), returns the file's
- permissions in system-dependent symbolic form (unlike zgperm(), which returns
- them in system-dependent numeric form). Probably will need lots of #ifdefing
- when I go build on many platforms... ckufio.c, 17 Dec 98.a
- Back to the built-in DIRECTORY command: domydir(). Added /BRIEF and /VERBOSE
- switches; /VERBOSE means to print the heading and summary; /BRIEF means to
- just list filenames as compactly as possible; if neither is included, a
- verbose listing is printed but without heading and summary. Added askmore()
- for paging, plus /PAGE /NOPAGE switches to control it. Changed date format to
- ISO standard yyyymmdd hh:mm:ss -- no English month names or screwy American
- month-day-year, and /ENGLISHDATE switch to re-enable English rather than ISO
- dates. Added display of permissions for UNIX. Rearranged fields to be more
- familiar and less DOS-like. ckuus6.c, 17 Dec 98.
- Then I discovered that all the code I had rewritten is duplicated (for OS2
- only) in dodir(). I don't understand the ONETERMUPD business so I left it
- alone, but I *think* that entire mass of code can be yanked out and replaced
- by a call to domydir().
- Added some #ifdefs to new UNIX permissions-printing code for symbols that some
- platforms might not define. ckufio.c, 18 Dec 98.
- Made zgetfs() return size even if it's not a regular file, since we only use
- it for directory listings. (NOTE: This change should not be made for K95,
- since DOS users are not accustomed to seeing the size listed for directory
- files). ckufio.c, 18 Dec 98.
- Added dashes to ISO numeric date in DIRECTORY listing -- too hard to read
- without them. ckuus6.c, 18 Dec 98.
- Made UNIX DIRECTORY show file size for directories too. ckuus6.c, 18 Dec 98.
- Made K95 call domydir() instead running special code. ckuus6.c, 18 Dec 98.
- Made server-side directory listing code compatible with domydir(). nxtdir(),
- ckcfns.c, 18 Dec 98. (Project for a rainy day: consolidate sndir(), nxtdir(),
- and domydir().)
- From Jeff: it turns out that the parameter passed to the getc() function that
- is given to tn_doop() is not really a dummy after all. tn_doop() passes a 0
- value to the function because it is expecting a blocking read. This was not
- happening. tn_doop() was also not checking the return code of the getc()
- function and was converting it to a char. So -1 (timeouts) was being treated
- as IAC. Fixed in ckutio.c, ckcnet.c, 18 Dec 98.
- From Jeff: Mutexes in K95 for local-echo buffer vs connection. ckcnet.c
- 18 Dec 98.
- Added a new DIRECTORY command switch, /HEADING, to decouple printing of
- headings and summaries from /VERBOSE and /BRIEF. ckuusr.h, ckuus6.c,
- 18 Dec 98.
- Added a new command to set default options for other commands that take
- switches: SET OPTIONS <command> <switch> [ <switch> [ ... ] ]. ckuusr.[ch],
- ckuus3.c, 18 Dec 98.
- But this meant that each option requires an opposite, so added /NOHEADING,
- and /ISODATE. ckuusr.h, ckuus6.c, 18 Dec 98.
- Filled in SET OPTIONS DIRECTORY [ switches ]. ckuus6.c, 18 Dec 98.
- Changed filhelp() to return 1 if it listed all the files, and 0 if the listing
- was terminated prematurely (by the user replying "n" to askmore()), to allow
- DIR /BRIEF /HEADING to work. ckucmd.c, ckuus6.c, 18 Dec 98.
- Added HELP text for DIRECTORY and SET OPTIONS. ckuus2.c, 18 Dec 98.
- Cleaned out hundreds of lines of cruft from dodir(). ckuus6.c, 18 Dec 98.
- Fixed streaming glitch introduced on Dec 16. ckcfns.c, 18 Dec 98.
- Minor changes from Jeff to ckcdeb.h and ckcnet.c, 20 Dec 98.
- Moved sh_sort() to ckcmai.c with other general-purpose utilities and added
- key & reverse parameters. ckcdeb.h, ckucmd.c, ckcmai.c, 20 Dec 98.
- Added /[NO]RECURSIVE, /NOSORT, /SORT:{NAME,DATE,SIZE}, /ASCENDING,
- /REVERSE (= /DESCENDING) switches to DIRECTORY and SET OPT DIR commands:
- ckuusr.h, ckuus6.c, 20 Dec 98.
- Fixes from Jeff. ckcnet.c, ckuus6.c, 21 Dec 98.
- Moved SET OPTIONS keyword table to top level since aggregate initialization
- of structs is not portable. ckuus6.c, 21 Dec 98.
- Filled in zgperm() and ziperm() for VMS. Made VMS zgetfs() return file size
- even for directories. Added zrelname() to convert a full pathname to one that
- is relative to the current directory (needed only for VMS).
- ckvfio.c, 21 Dec 98.
- Made filhelp() for VMS return zrelname()-shortened names. ckucmd.c, 21 Dec 98.
- Made domydir() work for VMS. ckcdeb.h, ckuus6.c, 21 Dec 98.
- Various directory listing improvements. Don't give "more?" prompt if last
- line that was shown is the actual last line. Made more-prompting take
- wrapping of long lines into account, watching out for lines that are exactly
- the column width. Lots of other checking added, boundary conditions handled,
- etc. ckuus6.c, 21 Dec 98.
- Added SHOW OPTIONS. ckuusr.h, ckuus[56].c, 21 Dec 98.
- Updated HELP DIRECTORY text. ckuus2.c, 22 Dec 98.
- From Jeff: Corrections to fscrncur[xy](); they do not require arguments.
- ckuus4.c, 23 Dec 98.
- From Jeff: SET TERM SPACING-ATTRIBUTE-CHARACTER (invisible, a debugging tool).
- ckuusr.h ckuus7.c, 23 Dec 98.
- Tried changing SYS$OPEN() to SYS$DISPLAY() in zgperms(), but result was
- error 99684 "invalid internal file identifier".
- Changed xxstrcmp() (caseless string compare) to ckstrcmp() (string compare in
- which case-matters is a parameter), and defined xxstrcmp() to be a macro that
- calls ckstrcmp() with the parameter set to 0, but changed all references to
- xxstrcmp(a,b,c) to ckstrcmp(a,b,c,0) anyway. ckcker.h, ckcmai.c, 23 Dec 98.
- Replaced all constructions like:
- x = casematters ? strcmp(a,b,c) : xxstrcmp(a.b.c)
- with ckstrcmp(a,b,c,casematters). Many modules, 23 Dec 98.
- Added a "case matters in filenames" constant: filecase (1 for UNIX and OS-9,
- 0 elsewhere). ckcdeb.h, ckcmai.c, 23 Dec 98.
- Added a "case matters" parameter to sh_sort(). ckcker.h, ckcmai.c, 23 Dec 98.
- Changed filename "?" and directory sorts to obey filecase setting by passing
- filecase as an arg to sh_sort(). ckucmd.c, ckuus6.c, 23 Dec 98.
- Added SHOW ARRAY &x to display the contents of array x. Previously SHOW
- ARRAY did not take an argument, but simply listed all defined arrays.
- ckuus6.c, 23 Dec 98.
- Added SORT [ { /CASE:{ON,OFF} /KEY:n /REVERSE /SIZE:n } ] <array>. Testing
- this by reading a file into an array and then sorting it revealed all sorts of
- holes in the recently updated string comparison and sorting routines --
- e.g. when the key is off the end of the string, or when one of the elements to
- be compared is null, etc. Plugged all of these. ckuusr.[ch], ckuus[56].c,
- 23 Dec 98.
- From Jeff: Move "<DIR>" to left of size column for sorting purposes.
- Fix SET PRINTER /W.. to accept abbreviations for /WINDOWS-Q that worked
- prior to adding /WIDTH. ckuus[36].c, 24 Dec 98.
- Discovered that a typo yesterday's changes broke IF EQUAL. Fixed in doif(),
- ckuus6.c, 24 Dec 98.
- Changed ffiles() and related functions (fdir(), etc) to take a second arg,
- an array 'pointer', to make array contain file list, e.g. ffiles(*.txt,&a).
- Element 0 of the array contains the size of the list, and elements 1..n
- contain the filenames. NOTE: This does not work in K95 because I didn't see
- any obvious way to access the alternative "znxt" list -- probably we just need
- to remove the #ifdef OS2 from the code in fneval FN_FC that calls znext() in
- a loop to make a copy of the file list. ckuus4.c, 24 Dec 98.
- Added HELP SORT text. ckuus2.c, 24 Dec 98.
- From Jeff, 24 Dec 98:
- . Fixed memory (de)allocation problems in ffiles(): ckuus4.c.
- . Add ffiles() array assignment for K95: ckuus4.c.
- . Add Wyse160 emulation (=WY60+blockmode): ckuusr.h, ckuus[257].c.
- Fixed Jeff's corrections (don't call makestr() with uninitialized pointers,
- some fencepost errors). ckuus4.c, 25 Dec 98.
- Updated HELP FUNCTION text for f[r]files(), f[r]directories(). ckuus2.c,
- 25 Dec 98.
- Fixed some glitches in SORT command parsing. ckuusr.c, 25 Dec 98.
- Fixed UNIX CONNECT module to log incoming characters to session log BEFORE
- translation (etc) if session log is binary. If session log is text, chars
- are logged after translation (etc), as before. ckucns.c, ckucon.c, 25 Dec 98.
- Added SET OPTIONS TYPE { /PAGE, /NOPAGE } and added TYPE to SHOW OPTIONS,
- just so we don't have only one command we can set options for. ckuus[r5].c,
- 25 Dec 98.
- A few more fine adjustments to ffiles() array code. ckuus4.c, 26 Dec 98.
- Realized that we really need to allow the user to specify both the start and
- end range of elements to be sorted, in case they really do want to use 0-based
- arrays (or they want to sort pieces of arrays for some reason). Changed
- /SIZE:n to /RANGE:n:m. Also, moved the SORT command code from ckuusr.c to
- cuus7.c. 26 Dec 98.
- Used the new "parse-a-range technology" to allow SHOW ARRAY a[n:m]. ckuus5.c,
- 26 Dec 98.
- Discovered still more problems in SORT switch parsing, mainly that command
- retry and recall were totally fouled up. The reason was quite subtle. The
- object was to parse SORT [ switches ] array-name. Now, to allow for the
- possibility that the user might type &a as the array name (i.e. include the
- initial backslash), this required the switch keyword table to have a NULL
- processing function, rather than the customary xxstring, otherwise cmkey()
- would run xxstring on the array name and fail because the result did not match
- a keyword from the table. The problem was that the path taken through cmkey()
- when the processing function was NULL had never been used before, and
- therefore never debugged: the wordlength variable was improperly set in this
- case, and (more interestingly), upon reparse, gtword() would return the
- switch together with its argument, and therefore the assumption that it had
- broken on the ":" or "=" was violated, and therefore the switch *with* its
- argument was looked up in the keyword table, which naturally failed. Fixed
- in cmkey2(), ckucmd.c, 26 Dec 98.
- Fixed all array-name parsing functions to allow for the &@[] array (a
- special case). ckuus5.c, 26 Dec 98.
- Another minor correction to ffiles() array management. ckuus4.c, 27 Dec 98.
- Updated HELP SORT text. ckuus2.c, 27 Dec 98.
- Updates to Telnet code from Jeff to accommodate sparse Telnet option arrays.
- ckctel.h, ckcnet.c, 27 Dec 98.
- Updated NEWS command. ckuus2.c, 27 Dec 98.
- NeXTSTEP was missing symbol definitions for most of the permission bits in
- <sys/stat.h>. Added #ifndefs for them. ckufio.c, 27 Dec 98.
- Fixed misplaced #ifdef CK_TTGWSZ in domydir(): ckuus6.c, 27 Dec 98.
- Defined UTIMEH for HP-UX 9.0. ckufio.c, 27 Dec 98.
- Got rid of getuid(), etc, prototypes for HP-UX 9.0. ckutio.c, 27 Dec 98.
- DECC 5.5 on VMS 7.1 is great at finding stuff the other compilers don't:
- . Missing prototypes for sopkt() and zrelname(). ckcdeb.h, ckcker.h.
- . Missing prototype for lower(), and signed vs unsigned char casts
- for args to various lower(), le_getchar(), etc. ckcnet.c.
- . Missing prototype for iks_wait(). ckctel.h.
- . Missing prototype for cmswi(). ckucmd.h.
- . sb[] used before declared. Moved declaration up. ckcnet.c.
- . Decomposed the statement "len = (xunchar(*p++) * 95) + xunchar(*p++)",
- which elicited a rather stern warning. ckcpro.w.
- . The prototypes for some of the Kanji translations were in #ifdef KANJI
- in ckcker.h. But KANJI was defined in ckcxla.h, which was included *after*
- ckcker.h. Moved the errant prototypes from ckcker.h to ckcxla.h, where
- they belonged. ckcker.h, ckcxla.h.
- . Removed obsolete reference to me_binary from ckvcon.c.
- . Many more like this.
- After all this I get clean builds on VMS 7.1 with DECC. 27 Dec 98.
- Removed curses support from QNX16 version. See notes in makefile. 27 Dec 98.
- Fixed typos in ckuus3.c and ckucon.c, noticed during X.25 build. 27 Dec 98.
- ---7.0 Beta.02---
- From Jeff, 30 Dec 98:
- . Define & implement two new responses for Telnet IKS negotiation.
- . Define & implement several features for Pragma Systems telnet client.
- . Fixes for K95 VIEW command.
- Changed copyright to 1999. All modules, 30 Dec 98.
- Added BSDI 4.0 target & banner. makefile, ckuver.h, 30 Dec 98.
- Increased Olimit for IRIX 6.4 build to stop warnings. makefile, 30 Dec 98.
- #ifdefs for SCO 3.2v5.0.x perror() prototype vs gcc. ckcdeb.h, 30 Dec 98.
- #ifdefs for SCO 3.2v5.0.x perror() declaration and contents (void vs int
- return type). ckuusx.c, 30 Dec 98.
- Added missing #ifdef DEBUG around code in shocps() that referenced deblog.
- ckuusx.c, 30 Dec 98.
- Added code to check if, upon CONNECTing, the Telnet server is actually an
- IKSD in server mode, and in that case to return to the prompt. ckucns.c,
- ck[uvd]con.c, 30 Dec 98.
- Broke up a complicated printf() that blew up the Motorola SVR3 compiler.
- shotopt(): ckuus4.c, 30 Dec 98.
- Fixed some help-text typos. ckuus2.c, 30 Dec 98.
- Jeff pointed out that UNIX C-Kermit is dropping Telnet negotiations because
- ttflui() doesn't check for Telnet negotiations. The big switch statement in
- ttinl(), which checks for IAC and if we're doing Telnet protocol, calls
- tn_doop(), and then handles its return code, has to be duplicated in ttflui().
- So I moved the switch() statement to a new routine, tt_tnopt(), and called it
- from ttinl(). This didn't seem to break anything, so then I placed calls to
- tt_tnopt() into ttflui() and ttflux(). This didn't seem to break anything
- either, but it will need testing in the situations where negotiations were
- being lost before. ckutio.c, 30 Dec 98.
- Corrections to yesterday's ckutio.c changes plus some other stuff from
- Jeff, various modules, 31 Dec 98.
- Adjustments to makefile & source modules for AT&T 7300 and other entries based
- on SVR3 and earlier -- add:
- -DNOSYSLOG -DNOSYMLINK -DNOGETUSERSHELL -DNOINITGROUPS -DNOFTRUNCATE
- to CFLAGS, and make sure all the appropriate #ifdefs are in place. Also,
- add #ifndef NOGFTIMER to an unguarded reference to fpfsecs. makefile,
- cku[tf]io.c, ckuusx.c, 31 Dec 98.
- Corrected yet another problem in ckindex() when told to search from the right.
- ckuus4.c, ckcmai.c, 31 Dec 98.
- Fixed IF MATCH to actually pass the SET CASE variable to ckmatch(), like it
- was alway supposed to. ckuus6.c, 31 Dec 98.
- Reworked ckmatch() to allow quoting of metacharacters and single-character
- matching by [abc] (list of chars) or [a-z] (range of chars), or any
- combination. The code is not exactly elegant but I think it covers every
- conceivable combination (which I don't think elegant code can do). Tested
- extensively with "if match" over a hundred patterns ranging from those that
- might be commonly used to the truly bizarre. match.ksc, ckcmai.c, 31 Dec 98.
- Changed the match() call in ckufio.c to ckmatch(). Now it is possible to tell
- C-Kermit to "send ck[cuw]*.[cwh]". Of course, it also affects all other
- commands that parse filenames, as well as ? file lists, e.g. "send ck[cu]?".
- ckufio.c, 31 Dec 98.
- Fixed parsing of SET WILD SHELL when NOPUSH/nopush. ckuus3.c, 31 Dec 98.
- Verified ckmatch() works with 8-bit data, includeing 0xff. However, IF MATCH
- neglected to handle braces correctly so strings or patterns containing spaces
- didn't work right; fixed in ckuus6.c, 1 Jan 99.
- Added a new argument to ckmatch, telling whether to match strings that start
- with ".", to make UNIX filename globbing work as before. The new arg is the
- "matchdot" variable, set by SET WILD KERMIT /[NO-]MATCH-DOT-FILES, used only
- when calling from within zxpand(), otherwise always 1. ckcker.h, ckcmai.c,
- ckcfns.c, ckuus[56].c, ckufio.c, 1 Jan 99.
- Added {string1,string2,...} matching to ckmatch(), in which the strings
- themselves can be patterns, recursing to any reasonable level. ckcmai.c,
- ckermit2.txt, 1 Jan 99.
- Updated UNIX iswild() to know about new metacharacters, and also to know about
- quoting, which it never did before. ckufio.c, 1 Jan 99.
- Problem: At some point since last May (but before Beta.03) I broke parsing
- of quoted question marks in filenames, e.g.:
- send cku?io?
- Instead of listing several files like it should, it went nuts. Found & fixed
- the problem in gtword(): ckucmd.c, 1 Jan 99.
- Added CKREGEX and NOCKREGEX compile-time symbols. Use the latter to get rid
- of [] and {} globbing in case it produces undesirable effects. Otherwise
- CKREGEX is defined for all platforms. ckcdeb.h, ckcmai.c, ckufio.c, 1 Jan 99.
- Put SHOW PATTERNS in #ifdef PATTERNS so it doesn't show up on VMS, etc..
- ckuusr.c, 1 Jan 99.
- DISABLE DELETE prevented SET FILE COLLISION xxx in the client. Fixed the code
- so the check is made in the server. ckcfns.c, ckcpro.w, 1 Jan 99.
- More fixes to ckindex() so the optional 3rd argument is treated uniformly for
- both left and right searches. ckcmai.c, ckuus[24].c, ckermit2.txt, 1 Jan 99.
- A user reported that an ancient and hacked version of Kermit that is found on
- QNX2 and QNX3 systems, when it sends "&" in its parameter string to indicate
- it wants to do 8th-bit quoting, demands a response of "&" and does not accept
- "Y", which C-Kermit sends. Added an invisible command: SET Q8FLAG {ON,OFF}.
- When ON, this makes C-Kermit reply with the same 8th-bit quote character that
- the sender sent; when OFF (the default), it responds with "Y" as it always
- did. ckuusr.h, ckuus[r3].c, ckcfns.c, 1 Jan 99.
- DIRECTORY would print nothing and succeed if it ran out of memory when
- making a sorted listing. Now it prints "?Too many files match" and fails.
- ckuus6.c, 1 Jan 99.
- Updated gettcs() (which picks the intermediate character set for TRANSLATE,
- TRANSMIT, and non-K95 CONNECT to account for Latin-9, CP858, and CP1252 for
- Euro's sake, just in time! ckuus4.c, 1 Jan 99.
- Updated SHOW CHARACTER-SETS to account for Latin-9 as an intermediate set:
- shotcs(), ckuus5.c, 1 Jan 99.
- Corrections from Jeff to yesterday's changes. ckcmai.c, ckuus[23].c. 2 Jan 99.
- Discovered that UNIX coninc(x), where x > 0, returned -1 rather than -2 on
- timeout. When coninc() calls ttinc() the fix rather hideous -- see the code.
- ckutio.c, 2 Jan 99.
- Added SET ASK-TIMER n (sec), to make ASK and friends time out and fail if user
- doesn't supply an answer within n seconds. Works with ASK, ASKQ, GETOK, and
- GETC. ckuusr.h, ckucmd.c, ckuus[r36].c, 2 Jan 99.
- Added IF ASKTIMEOUT to let script writer test whether ASK-class command failed
- because of timeout. ckuusr.h, ckuus6.c, 2 Jan 99.
- Added --timeout:n for IKSD login. ckuusr.h, ckuus[25y].c, 2 Jan 99.
- Set a default time limit to log in to IKSD at 300 seconds (5 min). This works
- in the Username:/Password: dialog via the ASK-TIMER mechanism, and in
- client/server mode via some crude sampling of the system clock (not foolproof;
- if user client never sends anything I don't think the server will time out).
- ckcmai.c, ckuus7.c, 2 Jan 99.
- Updated help text for new commands and reformatted much of the help text for
- more consistent indentation and spacing. ckuus2.c, 2 Jan 99.
- VOS updates, etc, from David Lane & Jeff. 4 Jan 99.
- VMS updates from John Santos. ckcnet.c needs saddrlen declared as unsigned.
- DEC C 6.0 header files refer to a data type of u_int but don't define it
- anywhere, so a definition was added to ckcnet.h. Changed the name of rdata
- state in ckcpro.w to rdpkt, since the name rdata conflicts with a struct
- element defined in nameres.h. 4 Jan 99.
- Got rid of "Negotiations..." and spinner display when in remote mode.
- Only the client should print these. ckcnet.c, 4 Jan 99.
- Problem (which is not new): "dir /recursive */blah" matches all files in the
- current directory, because this becomes "./*/blah" and the "*" segment matches
- all files in the current directory (see traverse() in ckufio.c).
- Fix 1: At the point where we are adding a file because the search is recursive
- and the file is not a directory, match it with the original pattern. This
- filters out all the files whose names are different from the desired one, but
- since the current segment has "./" prepended to it, "*/blah" also matches
- "blah" in the current directory because "blah" has become "./blah". Also
- "dir /recu blah" matches nothing, even if "blah" is in the current directory
- and/or subdirectories.
- Fix 2: Like fix 1, but point past the leading "./" prior to the comparison.
- This makes "dir /recursive */blah" work exactly right, but it prevents "dir
- /recursive blah" from matching blah files in subdirectories because the
- pattern "blah" does not match "xxx/blah". But this is the right track. Note
- that * does not match slash in UNIX filename globbing; but in ckmatch() slash
- is just another character. Therefore, it's the responsibility of the file
- code to pass the right strings to ckmatch(). The trick is to note how many
- directory separators were in the original pattern, and then match strings
- containing that many segments. For example, if the original pattern is
- "oofa.txt" (1 segment), and we are matching ./aaa/bbb/oofa.txt (4 segments),
- we must strip 4 - 1 = 3 segments from the left before matching. Similarly, if
- the original pattern is */oofa.txt, we strip 2, and match with bbb/oofa.txt.
- So now suppose we have a directory tree in which oofa.txt files exist at all
- levels. "dir oofa.txt" shows the one at the current level. "dir /recursive
- oofa.txt" shows all the ones at all levels. "dir */oofa.txt" shows the ones
- one level down. "dir /recursive */oofa.txt" shows the ones one level down
- and lower. "dir /recursive */*/oofa.txt" shows the ones 2 levels down and
- lower, etc etc. fgen(), traverse(): ckufio.c, 5 Jan 99.
- More cleaning up & improving HELP text, especially HELP SET HOST. ckuus2.c,
- 5 Jan 99.
- Jeff broke the Telnet protocol out of ckcnet.c to a separate module, ckctel.c.
- 5 Jan 99.
- Changed UNIX makefile to account for ckctel.c. 5 Jan 99.
- Some changes to IKS server in/out switching from Jeff. ckcpro.w, 5 Jan 99.
- Jeff made dodir() call domydir() in K95. ckuus5.c, 5 Jan 99.
- Jeff made TELNET command add an implicit /TELNET at the send of the command.
- ckuus7.c, 5 Jan 99.
- Added HELP WILDCARDS. ckuusr.[ch], ckuus2.c, 5 Jan 99.
- Added SET F-ACK-BUG { ON, OFF } (invisible). ckuusr.[ch], ckuus3.c, ckcpro.w,
- 6 Jan 99.
- Added a section on coping with faulty Kermit implementations to ckermit2.txt,
- 6 Jan 99.
- Added messages to refer UNIX users to installation instructions when access
- to lockfile directory and/or dialout device is denied. ckuus7.c, 6 Jan 99.
- Moved common library routines from ckcmai.c to a separate module, ckclib.[ch],
- and updated the UNIX makefile to know about it. 6 Jan 99.
- Added code to protocol module to catch failure to negotiate Kermit server on
- Telnet connection. ckcpro.w, 6 Jan 99.
- Updated the VMS build procedure for ckctel and ckclib. ckvker.com, ckvold.com,
- 6 Jan 99.
- Updated the OS-9 build procedure for ckctel and ckclib. ck9ker.mak, 6 Jan 99.
- Updated the Plan-9 build procedure for ckctel and ckclib. ckpker.mak, 6 Jan 99.
- Updated the DG build procedure for ckctel and ckclib. ckdsrc.lis, 6 Jan 99.
- Updated the Amiga build procedure for ckclib. ckiker.mak, 6 Jan 99.
- Updated the VOS build procedure for ckctel and ckclib. cklker.mak, 6 Jan 99.
- Fixed various glitches in ckcnet/ckctel split uncovered by building in VMS.
- 6 Jan 99.
- Added fpermissions(file). ckuusr.h, ckuus[24].c, 6 Jan 99.
- Added v(lockdir) for UNIX. ckuusr.h, ckuus4.c, 6 Jan 99.
- Added IF READABLE and IF WRITEABLE. Each of these takes either a filename
- or a directory name. Getting them to work for directories was a hack (global
- variables again). Probably in K95 they should just always succeed. ckuusr.h,
- ckuus6.c, ck[uvd]io.c, 6 Jan 99.
- Note: These last several items are mainly in case we ever want to
- write an install-myself script.
- Some changes from Jeff to (in)visibility of Telnet-related keywords.
- ckuus3.c, 6 Jan 99.
- telnet.txt from Jeff added to docs. 6 Jan 99.
- Discovered that makelist(), which parses {{xxx}{xxx}...} lists (as in
- SEND /EXCEPT:) chokes on {{{xxx,yyy,zzz}}} -- i.e. when you want to put a
- new-format wildcard as the exception list. Fixed in ckuusr.c, 6 Jan 99.
- Fixed DIRECTORY /HEADING /RECURSIVE not to list the number of directories,
- since it's always 0 (zxpand() does not include directories in its list when
- called recursively). ckuus6.c, 6 Jan 99.
- Added DIRECTORY /[NO]DOTFILES for UNIX & OS-9. ckuusr.h, ckuus6.c, 6 Jan 99.
- Added SET HOST /NETWORK-TYPE:{TCP/IP,COMMAND,...}. No reason not to, and it
- was easy. Also made SET HOST /COMMAND invisible, since it is only a special
- case of /NETWORK-TYPE:. The /NETWORK-TYPE switch does not affect the global
- SET NETWORK TYPE. ckuusr.h, ckuus7.c, 6 Jan 99.
- Updated Telnet-related HELP text from Jeff. ckuus2.c, 7 Jan 99.
- The code I put in to prevent "Negotiations...." from coming out of IKSD also
- prevented it from coming out of the client. Fixed in tn_wait(), ckcnet.c,
- 7 Jan 99.
- Discovered the server end of REMOTE DIRECTORY is broken in UNIX for huge
- directories. Local directory listings are fine. A packet log reveals that
- the transfer looks normal, but the data ends early. Debug log shows "sending
- packet out of window" for every data packet, but that always happens when
- streaming. Changed spack() not to log this message when streaming. ckcfn2.c,
- 7 Jan 99.
- The problem turned out to be not the size of the directory, but the fact that
- it contained a file with an 8-bit name, and we were storing the filenames in a
- char array instead of an unsigned char array. Returning an 8-bit signed char
- from int nxtdir() caused its sign to be extended, and a negative return signals
- EOF. Fixed in nxtdir(), ckcfns.c, 7 Jan 99.
- Discovered that the VMS C-Kermit Telnet client on UCX makes the connection OK,
- but loses the hostname. But only if TCP REVERSE-DNS-LOOKUP is ON and only
- with certain hosts. Discoveries: (1) the fact that gethostbyaddr() returns
- non-NULL does not mean that h_name is set; and (2) netopen() writes into its
- hostname argument -- gak! Fixed netopen() to handle case (1) by filling in
- the IP address if no name comes back, and also to issue its "blah connected on
- port blah" messages a bit more consistently. Left (2) alone, sleeping dogs
- department... ckcnet.c, 7 Jan 99.
- Discovered that VMS tthang(), in the network case, closed and then reopened
- the network connection. Fixed it to just close it. ckvtio.c, 7 Jan 99.
- Fixed a place where quiet was not restored before returning from doconect().
- ckuus4.c, 7 Jan 99.
- Added code to UNIX traverse() to make it return directory names during
- recursive traversal, as well as filenames. This was a bit tricky due to the
- possibility of showing or not showing dot files. If we are not showing dot
- files in UNIX, then we should not descend into any directory whose name
- starts with a dot. (In fact, this issue had never been addressed before,
- but now it's fixed.) ckufio.c, 7 Jan 99.
- Commented out the check against summarizing directories in DIR /HEADING
- /RECURSIVE, since directory files are now shown. ckuus6.c, 7 Jan 99.
- Checked "send /recursive", and of course it was broken, since gnfile() never
- expected to be fed a directory by znext(). We'd have the same problem in K95.
- Added a check to gnfile() to skip over directory files; recursive sends seem
- to be working again. ckcfns.c, 7 Jan 99.
- Discovered that "send ." no longer recursed. Did it ever? ckermit2.txt
- is contradictory on this, so I fixed it by removing any claims that "send ."
- implied /RECURSIVE. ckermit2.txt, 7 Jan 99.
- "send /recursive ." now dies with a parse error when the current directory
- happens to contain at least one subdirectory, and the first file returned when
- expanding "." happens to be a directory file. I patched this in both cmifi()
- and zxpand(); the former by checking the global recursive flag (yuk) and the
- latter by simply translating "." to "*". This works OK, but "send /recursive
- .." still doesn't work, even though "send .." does. Well, there's no end to
- this, so the clever thing to do is to have zxpand() call xfnqfp() on its
- argument up front. This nicely takes care any kind of crazy path (like
- .././../baz/../../foo.bar) that the user could dream up, not to mention
- tildes, etc. But that would be too easy.
- In fact, "send /recursive .." actually DOES work. The problem is the same as
- with putting zfnqfp() into zxpand(), or for that matter, specifying a full
- pathname or a pathname starting with tilde in combination with /RECURSIVE,
- namely that splitpath and traverse go through the ENTIRE FILE SYSTEM, file by
- file, which can take hours and in any case grinds the disk to dust. This is
- independent of today's change to make zxpand() return directory files; the
- same thing would have happened any time since we added SEND /RECURSIVE, and
- indeed it happens with 6.1 Beta.05 from last May: "send /recursive ~/tmp/*"
- does the trick quite nicely in /usr/local/bin/wermit.
- Hacking away at this, I managed to more or less fix it but some glitches
- remain. First of all, the parsing of "." and ".." etc stopped working again.
- But now I can put back zfnqfp() in zxpand() and all's well, except now we
- always get fully qualified names rather than relative ones, so I had to back
- off on that one for now. Another problem is that "dir /recursive <dirname>"
- only shows directories, not files, in any directory that is subordinate to the
- one named in the command. OK, close... Will finish this tomorrow.
- ckufio.c, 7 Jan 99.
- Fixed lingering problems in UNIX wildcard expansion. ckufio.c, 8 Jan 99.
- Changed zxpand to append path separator to any directory names it returns.
- ckufio.c. 8 Jan 99.
- Since we don't know whether all implementations of zxpand() will return
- directory names with separator appended, high-level code that does this in
- various places (e.g. filhelp(), cmifi2()) still does it, but only if it was
- not done already. ckucmd.c, 8 Jan 99.
- Added DIRECTORY /FILES (to show only regular files) /DIRECTORIES (to show only
- directories) and /ALL (default, to show files and directories). ckuusr.h,
- ckuus6.c, ckermit2.txt. 8 Jan 99.
- Changed SWITCH to evaluate case labels with zzstring() and then use ckmatch()
- on them rather than strcmp(). Now we can have shell-like switch statements
- with variables/functions/patterns as cases. ckuus6.c, ckermit2.txt, 8 Jan 99.
- Still have lots of details to clean up, will do them next week.
- From Jeff: The Telnet Negotiation delay mechanism has been redesigned once
- again. The requirement is not that WILL/DO negotiations can't be sent before
- encryption is active, just that none of the subnegotiation data be sent before
- the encryption is in place. So now there is a method to delay sending
- subnegotiation data until after START_TLS, AUTH, and ENCRYPT are complete.
- This means that we send all WILL/DO messages other than ENCRYPT before waiting
- for the AUTH response. If AUTH is refused we are done and there should be
- almost no delay when connecting at the expense of more complex code. And
- since the NAWS is now sent to the telnetd before "login" is started it works
- the first time and the SIGWINCH is not generated in the subprocess which
- interrupts the "Password:" read attempt. Also, it seems that I never added
- the DO case for TELOPT_SNDLOC. We would have negotiated SNDLOC but never sent
- the subnegotiation. So that is now fixed. (End quote) ckctel.[ch],
- 11 Jan 99.
- Also from Jeff: typo in krbmit entry fixed, makefile, plus some K95-specific
- stuff: ckuus[27].c, 11 Jan 99.
- Updated HP-UX entries from Peter Eichhorn, 11 Jan 99.
- The "Negotiations... (OK)" message was coming out twice, which is annoying
- especially now that Telnet connections are so much quicker. There did not
- seem to be any easy way to consolidate the two messages, so instead I added
- some code so they would print only upon a negotiation timeout. So this speeds
- up the connection even more (I didn't touch the spinner code, but it probably
- could use the same treatment). ckctel.c, 11 Jan 99.
- Made the UNIX DIRECTORY command handle symlinks. Of course this depends on
- the nonportable lstat() function, so another pile of #ifdefs in ckcdeb.h, and
- then some additional #ifdef'd code in domydir(). Now we get permissions,
- date, size, and name of the symlink, plus a "->" pointer to the linked-to
- file. To do this as efficiently as possible, I made zgetfs() have some side
- effects: since it's calling (l)stat() anyway, it also gets the link info, and
- also sets a flag saying whether the file is a directory. But we only take
- advantage of this in the DIRECTORY command where it can't do any harm.
- Of course, Yet Another Global Flag (diractive) had to be used to indicate to
- the low-level routines (zfcdat(), zgperm(), ziperm(), etc) whether to call
- stat() or lstat(), since we only want to call it for DIRECTORY commands, not
- file transfer, etc. Yuk. ckcdeb.h, ckufio.c, ckuus6.c, 11 Jan 99.
- As of yesterday, "dir <anypath>/*/filename" didn't work. Similarly for "dir
- <anypath>/*/*/filename", etc. Fixed in traverse(), ckufio.c, 12 Jan 99.
- "directory /recursive blah" (where "blah" is a filename, or in fact any
- pattern other than "*") doesn't work -- as far as I can tell, it never did.
- This should list all occurences of "blah" in the current (or given) directory
- tree, at any and all levels at which it occurs. After several more hours of
- pounding on traverse() I got this working too. ckufio.c, 12 Jan 99.
- But now "dir /recursive" shows dotfiles even when it shouldn't. Fixed that
- too. But every fix breaks something else. So now DIR /DIR * doesn't work any
- more. Fixed that. But now DIR /RECURSIVE /DIR lists each directory twice.
- Attempts to fix that broke everything else. I hate this routine. Finally
- after more fixing, all of the following work:
- dir
- dir /files
- dir /directories
- dir /recursive
- dir /recursive /files
- dir /recursive /directories
- dir oofa.txt
- dir /recursive oofa.txt
- dir /recursive *.txt
- dir *.txt
- dir */*.txt
- dir */*/*.txt
- dir .*
- dir /recursive .*
- dir /dotfiles
- dir /dotfiles /recursive
- dir foo (where "foo" is a directory name)
- dir .
- dir ..
- Obviously there are many more combinations, but these are the only ones
- that affect which files are shown and which ones aren't. Also checked:
- ffiles(*)
- frfiles(*)
- fdirectories(*)
- frdirectories(*)
- These work too, with both SET WILD KERMIT /MATCH-DOT and /NO-MATCH-DOT.
- But then there was some new trouble matching dotfiles in certain contexts, for
- example "dir {{*,.*}}" or "dir [.abc]". Made a minor correction to ckmatch()
- for this. ckclib.c, 12 Jan 99.
- Updated HELP IF text. ckuus2.c, 12 Jan 99.
- Changed TRANSMIT in the text / prompt 0 / pause 0 / echo off case to send
- 1K buffers rather than lines. Speeds up transmission by about 35% in this
- case. Didn't bother with binary mode since nobody uses it anyway, and the
- changes for that are a bit harder. ckuus4.c, 13 Jan 99.
- Updated HELP DIR, HELP SWITCH, HELP SET FILE, and HELP WILDCARD text.
- ckuus2.c, 13 Jan 99.
- Got tired of hunting for things in the SHOW FEATURES compiler options list,
- so changed SHOW FEATURES to sort them. Also fixed the paging, which had
- drifted a bit with new additions. ckuus5.c, 13 Jan 99.
- Added DIR /[NO]XFERMODE. If /XFERMODE is included, the directory listing
- shows the transfer that would be used for each based on the current patterns.
- If none is shown, then the filename doesn't match any patterns. This seems
- like a useful addition to a Kermit directory listing. ckuusr.h, ckuus6.c,
- 13 Jan 99.
- Added DIR /[NO]BACKUP. If /NOBACKUP is included, backup files (*.~*~) are
- not shown. ckuusr.h, ckuus6.c, 13 Jan 99.
- Added SEND /NOBACKUP. If /NOBACKUP is included, backup files are not sent.
- ckuusr.[ch], ckuusx.c, ckcfns.c, 13 Jan 99.
- Added SET SEND BACKUP { ON, OFF } to establish the global setting that SEND
- /NOBACkUP would override (SET RECEIVE BACKUP too, for symmetry, but it does
- nothing - just prints a message). Added SET SEND BACKUP status to SHOW
- PROTOCOL. ckuusr.h, ckuus[47].c, 13 Jan 99.
- Updated docs and help text. ckermit2.txt, ckuus2.c, 13 Jan 99.
- TRANSMIT was not always sending its last buffer in text mode. I don't think
- it ever did. Fixed in ckuus4.c, 14 Jan 99.
- Changed nzltor() (local-to-remote filename converter) to (a) replace space by
- underscore rather than X, (b) replace tilde by hyphen rather than X, and (c)
- translate non-ASCII chars to ASCII. The latter works effectively if the file
- character-set has been properly set; otherwise it's no worse than before (this
- does not address the larger question of proper translation of filenames).
- Converted filenames are now much more readable, especially backup files:
- foo.bar.~3~ becomes FOO_BAR.-3- rather than FOO.BARX3X, and accented letters
- lose their accents rather than coming across (in most cases) as box-drawing
- characters, etc. ckufio.c, 14 Jan 99.
- Trials show that the time to sort a directory listing is imperceptible, at
- least compared with the time to read the directory, so I made /SORT:NAME the
- default except in VMS, where directory names are returned in alphabetical
- order anyway. I did not do this for server-generated directory listings --
- that is a much bigger project, deferred til next time. ckuus6.c, 14 Jan 99.
- Updates to Minix 2.0 support from Terry McConnell, Syracuse U, ckcdeb.h,
- ck[tu]fio.c, makefile, 14 Jan 99.
- Lots of #ifdef adjustments, casts, etc, for building different configurations,
- many modules, 14 Jan 99.
- winchh() and sw_armed were used in ckctel.c but unknown to them. I thought I
- could move them from ckcnet.c to ckctel.c, but that didn't work, so I left
- them in ckcnet and extern'd them from ckctel. Builds OK, but NAWS operation
- needs to be checked.
- Somebody did something to utmp.h in Linux recently which makes it impossible
- for any application that includes that file to have variables, functions, or
- macros called local, screen, telnet, rlogin, xterm, rsh, ftp, unknown, or X
- (see "enum utlogin"). Swell. (This was noticed in mklinux, but not in the
- Intel version -- same kernel number; double swell.) There was no good way to
- avoid the conflict, so (a) I renamed our screen() routine to ckscreen(), along
- with all references to it. (b) was harder, since there are about 1000
- occurrences of the string "local" in the C-Kermit source, some of them
- embedded in other strings (e.g. "localtime()") or in comments or text); I
- wasn't about to change all of them at the last minute. Adding -Dlocal=cklocal
- doesn't help either; enums are "too powerful". The obvious solution was to
- build for Linux with -DNOWTMP, but that would eliminate some prominent
- convenience items, not to mention IKSD logging. Because of the utter
- stupidity of the C language, there was no way to #include <utmp.h> and avoid
- these conflicts, so finally I just hardwired the needed definitions from
- utmp.h and utmpbits.h into ckufio.c. YUK!!! 14 Jan 99.
- The new TELOPT macros defined in ckctel.h were too complex for some compilers
- (preprocessors) to handle so Jeff added a -DNOTOMACROS switch and accompanying
- code to allow their replacement by compiled functions. Also, a correction
- from Jeff to logstr(). ckctel.[ch], ckuusx.c, 14 Jan 99.
- Discovered the base Solaris entry had not been converted from ckucon to ckcns.
- Fixed in makefile, 14 Jan 99.
- hpux500wintcp -- try with xermit.
- look for prototype for inet_ntoa() in hpux headers.
- aos kermit got a stack dump / traceback because free() was called from
- close() which was called (on the tty) from _exit. Hmmm -- not Kermit's
- problem.
- --- Beta.03 ---
- Corrections from Jeff to IKS negotiations: ckctel, ckcnet, ckuus4, ckcpro;
- plus some character-set fixes: ckouni, 17 Jan 99.
- Moved extern int nnets outside of #indef NODIAL so -DNODIAL builds would work.
- ckuus7.c, 17 Jan 99.
- Added missing "Solaris 7 implies Solaris 2.6" clause to ckcdeb.h, 17 Jan 99.
- Some shuffling of #ifdefs in an attempt to fix broken compilation on Sinix
- 5.43 and Pyramid. Generalized the "gettimeofday takes one arg instead of two"
- business, instead of making it specific to Motorola SV88R4. ckutio.c,
- 17 Jan 99.
- Removed iks_wait() call that was in the middle of REMOTE command parsing.
- No actions should occur until after cmcfm(). This was making "(OK)" messages
- appear in the middle of typing any REMOTE command. ckuus7.c, 17 Jan 99.
- Some #ifdef juggling for HP-UX 10.01 to eliminate compiler warnings about
- select() and localtime(). ckutio.c, 18 Jan 99.
- From Jeff: Some additional changes for VOS; expanded TELOPT command;
- various modules, 18 Jan 99.
- New TELOPT command options are "ao", "ayt", "break", "cancel", "ec", "el",
- "eof", "eor", "ga", "ip", "dmark", "do", "dont", "nop", "sb", "se", "susp",
- "will", "wont". This lets us send any Telnet command at all; e.g. as a probe
- to see if the connection is up (e.g. NOP). (I changed some of the return
- codes; pls check.) ckuusr.c, 18 Jan 99.
- Tested this a bit, using TELOPT NOP or TELOPT DMARK as a probe. If I kill
- the remote process, these still succeed, even if I wait a while first. The
- second one fails. Seems strange -- how do we document this? "To see if the
- server is still there, use "telopt nop, telopt nop, if success ..."
- Refined the "Negotiations....(OK)" suppression code a bit. Much better now,
- but still not perfect. More later... ckctel.c, 18 Jan 99.
- Got access to an SCO 3.2V4.2 system and made necessary adjustments to get
- successful builds, mainly #including <sys/time.h> and linking with -lsocket
- so we can use gettimeofday for the high-precision timers, etc. I'm not sure
- if no-net systems can run a binary that is linked with -lsocket, but let's
- hope so... Converted these entries to xermit, since we can use select().
- makefile, cku[ft]io.c, ckuver.h, 19 Jan 99.
- Added sco32v4ns entry to build a version that does not use the sockets
- library, select(), or gettimeofday(), just for safety. Also, this was a good
- verification that -DNOGFTIMER still does its job. makefile, 19 Jan 99.
- Took all the -DNOSETBUF's out of the makefile and just set it in ckcdeb.h.
- (I thought I had done this before...) makefile, 19 Jan 99.
- Fixed IKSD not to refuse to send a file just because client does not have
- TERM AUTODOWLOAD ON. ckcpro.w, 19 Jan 99.
- Some changes from Jeff for K95 keyboard settings. ckuusr.h, ckuus7.c,
- 19 Jan 99.
- From Jeff, 20 Jan 99:
- . Fix bug in CLEAR INPUT: ckuusr.c.
- . Help text for SET TERM DG-UNIX-MODE: ckuus2.c.
- . Added table of DEC keyboard (terminal) languages + parsing: ckuus7.c.
- Fixed some bad notation in the IRIX 6.4 entry (-OPT:Olimit=3000 should have
- been -Olimit 3000; the former notation is not used until IRIX 6.5, silly me).
- makefile, 20 Jan 99.
- Added "-b elf" to SCO 5.0.4 and .5 non-gcc entries to avoid making COFF
- binaries (which is bad because...?). makefile, 20 Jan 99.
- Added HPUX6 and HPUX7 symbols to the appropriate makefile entries, since all
- the other HPUX's had their own. Added custom banners for HPUX 6 and 7. Added
- code to the network module to include <arpa/inet.h> for all HPUX except 7 to
- pick up the inet_ntoa() prototype (7 is excluded because it does not seem to
- have this header file, even though all the others do). makefile, ckuver.h,
- ckcnet.c, 20 Jan 99. (Builds OK with previous warnings gone on HPUX 9 and 10.)
- (Later confirmation received on HPUX 6 and 7.)
- NOSPL builds were failing due to unguarded references to mjd() in the
- connection log writer. Changed ckcdeb.h to set NOLOGDIAL if NOSPL was set.
- 20 Jan 99.
- Fixed some typos in ckermit2.txt. 20 Jan 99.
- Added code to display READ.ME file from current directory at startup if
- srvcdmsg != 0 (mainly for iksd). ckuus5.c, 20 Jan 99.
- Should TERM AUTODOWNLOAD be ON by default in C-Kermit (as it is in K-95)?
- . No, because the book says it isn't.
- . No, because C-Kermit is very likely to be in middle.
- But then what about when it is a client of IKSD? In that case it should be
- ON so SEND from the IKSD prompt will always work. But then if it's in the
- middle, we'll still have trouble if the local Kermit also has it on.
- So what are the choices?
- . Leave it alone. But this makes IKSD look bad.
- . Make it on by default? Causes confusion when C-Kermit in the middle.
- . Turn it on automatically when client of IKSD? (Save & restore)
- Well, yes, obviously we want it on when we're a client of IKSD. That's not
- the question -- the question is what do we do about the other, more local,
- Kermit that might also have it on? There's nothing we CAN do, so don't worry
- about it. Ideally, then, we would change SET TERM AUTODOWNLOAD { ON, OFF }
- to { ON, OFF, AUTO }, with AUTO being the new default, meaning "enable
- autodownload automatically if I make a connection to an IKSD". And I started
- to do it that way, but ran into conflicts with K95, which has a different and
- conflicting set of keywords, plus it was not obvious where the automatic
- switching should be done, nor where to undo it when the connection is broken
- or some other negotiation would change the rules. So I simply made the
- default be ON for all C-Kermits as well as K95. It's a lot easier to explain
- this way, and in fact the book goes into some detail about it in several
- places. ckcmai.c, 20 Jan 99.
- Changed SET FLOW AUTO to always SET FLOW NONE when making a direct serial
- connection, rather than setting it to RTS/CTS just because we know we can.
- The latter turned out to be a bad idea because a direct connection is very
- likely not to be giving us the CTS signal (or even have a wire for it), so any
- attempt to write will just hang. setflow(): ckuus3.c, 20 Jan 99.
- Changed "kermit -l" to also call setflow(), so we get consistent behavior
- with command-line and interactive device opening and i/o. ckuusy.c, 20 Jan 99.
- SINIX 5.43 changed gettimeofday() to have one arg instead of two. Added
- appropriate #ifdefs to ckutio.c, defines to the makefile entry, and a
- designer herald in ckuver.h. 20 Jan 99.
- Added -DSELECT -DNOGETUSERSHELL to pyrdcosx entry. makefile, 20 Jan 99.
- Fixed some long lines in ckuus2.c, 20 Jan 99.
- Changed BSDI product name from BSD/386 to BSD/OS, to reflect current usage
- since the 1.1 release. makefile, ckuver.h, 20 Jan 99.
- Lots of changes from Jeff to get rid of non-CKOUNI possibility in K95.
- Many modules, 20 Jan 99.
- Bug: "xif 1 { input 10 ), echo Thanks: [v(input)] }" produces garbage because
- the ")" caused the enclosing "flit()" (which is used internally by XIF and
- friends to prevent premature evaluation of its command blocks) to terminate
- early. Fixed in litcmd() by quoting any unbalanced right parentheses. Also
- added a destination length argument to litcmd() to prevent memory leaks. Also
- removed some really obnoxious debug() calls from litcmd(). ckuusr.h,
- ckuus[56].c, 21 Jan 99.
- Changed ODT 3.0 makefile entry not to contain an underscore, since these don't
- show up when underlined (e.g. in Web links). makefile, 21 Jan 99.
- Stripped out some obsolete comments from ckuus4.c, 21 Jan 99.
- Added a note about new TELOPT operands and cleaned up some typos in
- ckermit2.txt, 21 Jan 99.
- Fixed the "Negotations... (OK)" message again. The idea is: don't print
- "Negotiations" unless we get a timeout from tn_wait(). Once we get a timeout
- and print "Negotiations", then print "." every second till the wait is up,
- then print "(OK)". Don't print dots or "(OK)" if we didn't print
- "Negotiations". Don't print "(OK)" twice. AND... only do this upon initial
- connection, not during the session. This way, most people will never see
- this message; it will only appear when the connection is taking a long time,
- to let them know Kermit isn't dead. ckctel.c, 21 Jan 99.
- Moved lower() to ckclib, and renamed it to cklower(). ckucmd.c, ckuus5.c,
- ckclib.[ch], 21 Jan 99.
- Got rid of xindex() and replaced all references to it by references to
- ckstrchr(), which is in ckclib. ckufio.c, 21 Jan 99.
- New HP-UX makefile entries from Peter Eichhorn; updated "+/-/?" notations in
- comments at the top for C-K 7.0. makefile, 25 Jan 99.
- Some compilers have started to choke on "too many defines" in ckuusr.h. Put
- large blocks of K95-specific defines in #ifdef OS2..#endif, Telnet-specific
- defines in #ifdef TNCODE..#endif, etc. ckuusr.h, ckuus2.c, 25 Jan 99.
- From Jeff: TELNET /PASSWORD:<pswd>, SET HOST /PASSWORD:<pswd>, for SRP enabled
- versions of C-kermit. To allow scripted operation of SRP connections. Still
- need to figure out how to allow users to call SET LOGIN PASSWORD <pwd> in K95
- without the <pwd> being provided in an encrypted form. But for now, SET LOGIN
- PASSWORD will set a flag in K95 indicating that is where the password came
- from so we know whether or not to decrypt it in ckuath.c Also, added support
- for Preauthenticated Kerberos IV Ticket Getting Tickets, AUTH K4 INIT
- /PREAUTH. This provides an added layer of security by requiring that the
- user's password be used to encrypt the ticket getting ticket request. By
- configuring the server to require pre-auth ticket requests it becomes nearly
- impossible for an unauthorized user to request a TGT. Unfortunately, this
- does not work in K95 because Leash does not include the necessary
- functionality. It does work in C-Kermit. ckcnet.c, ckcmai.c, ckuus7.c,
- ckuus3.c, ckuath.h, ckuusx.c, ckuusr.c, ckuath.c, 25 Jan 99.
- Looking at recursive transfers in VMS...
- . SEND /RECURSIVE actually works as it should, as long as it's given the
- a filespec containing "...". The code is already there to accept the
- switch and set SEND PATHNAMES to RELATIVE automatically, and the files
- are indeed sent with relative pathnames.
- . GET /RECURSIVE did not set RECEIVE PATHNAMES RELATIVE, so I fixed that.
- ckuus6.c, 26 Jan 99.
- . I considered inserting "..." into the filespec, but that would be going
- overboard, plus how would it work in the middle of a parse, e.g. when "?"
- was typed in the filename, etc. Also, not all filespecs lend themselves to
- this, e.g. in "define foo [somedir], send /recursive foo:*.*" there is no
- place to put the "..." ("foo:[...]*.*" doesn't work).
- The /RECURSIVE switch for GET was in #ifdef RECURSIVE. That was wrong -- the
- client should be able to send this request to the server, even if the client
- itself does not support recursive transfers. The #ifdef was removed. And for
- symmetry, I added RECEIVE /RECURSIVE, which simply sets RECEIVE PATHNAMES to
- RELATIVE. ckuus6.c, ckermit2.txt, 26 Jan 99.
- Discovered that when C-Kermit receives a file that has the same name as an
- existing file into a directory that has many thousands of files (and FILE
- COLLISION is BACKUP or RENAME), it can take a loooong time to make the backup
- file name, since Kermit has to read the whole directory to find out which, if
- any, backup files already exist. The delay might be as long as 10-20 seconds,
- even a full minute. But C-Kermit 6.0 takes hardly any time at all in the same
- directory. Is it because of the new pattern matcher (ckmatch() instead of
- match())? Putting back match() makes it take even longer. traverse() is the
- culprit: it's now calling isdir() on every single file, which turns out to be
- a surprisingly expensive call. A little thought revealed it was OK to skip
- the call to isdir() in the nonrecursive case, since higher-level code will
- take care of filtering out unwanted directory files. ckufio.c, 26 Jan 99.
- Back to VMS... Compilation of ckuusr.c blows up due to new #ifdefs in
- ckuusr.h; it is now necessary to #include ckcnet.h before ckuusr.h, rather
- than after, so the various TCP-related symbols will be defined before they are
- referenced in #ifdefs in ckuusr.h. ckuusr.c, 26 Jan 99.
- Next problem: GET /RECURSIVE, when sent to a VMS server, always results in
- "Receive window full", even though it works fine with a UNIX server. Why?
- Once again, spurious #ifdef RECURSIVE..#endif around the supporting code.
- #ifdefs removed and the command now works. ckcpro.w, 26 Jan 99.
- Except that it's sending the pathnames in VMS format rather than standard
- (UNIX) format. Why? Because the client said to (K95 has FILE NAMES LITERAL
- by default). This is a problem because what is a non-VMS client going to do
- with VMS-format directory names? Unfortunately, the "fncnv" (filename
- conversion) flag is overloaded in this case: we might want to leave the file
- names unconverted but still need to convert the directory path syntax. This
- doesn't affect UNIX (even though it has the same bug) because its path syntax
- is the same as the standard one. To work around the problem for VMS only, I
- made an additional check in nzltor(), so now we convert the path syntax if
- FILE NAMES are CONVERTED *or* if the system ID of the other Kermit is not "D7"
- (the VMS system ID). ckvfio.c, 26 Jan 99.
- Additional SNI stuff from Jeff for K95. ckuusr.h, ckuus7.c, 26 Jan 99.
- Minor SNI and help-text changes from Jeff. ckuus[27].c, 28 Jan 99.
- Added horizontal text lines to mark entry to and exit from CONNECT mode (when
- not quiet). These are done only in the CONNECT modules, not in the mainline
- code, since terminal-emulating versions should not do this. Also the lines
- are not printed if QUIET is set or during APC transitions. ckucns.c,
- ck[duv]con.c, 28 Jan 99.
- If XFER DISPLAY is FULLSCREEN but terminal type is not recognized, fall back
- to CRT display, rather than SERIAL. ckuusx.c, 28 Jan 99.
- Added missing help text for SET SEND BACKUP. ckuus2.c, 28 Jan 99.
- "send /recursive ." doesn't work any more, even though "send ." does. "send
- /recursive .." doesn't work any more, even though "send .." does. "send
- /recursive /full/path/name" has gone back to trying to read the entire file
- system. Sounds familiar? This was all fixed on Jan 7th, but then broken
- again some time before Jan 14th. Fixed again today. ckufio.c, 28 Jan 99.
- Now all the tests from Jan 12th work except "dir /recursive oofa.txt", which
- fails to recurse. One more tiny tweak fixes this and now all tests work
- again. ckufio.c, 28 Jan 99.
- Fixed SET OPTIONS DIRECTORY /NOBACKUP, which wasn't working due to a typo.
- ckuus6.c, 28 Jan 99.
- Changed the server end of REMOTE DIRECTORY to obey SET OPTIONS DIRECTORY
- /[NO]HEADING, /[NO]DOTFILES, and /[NO]BACKUP. In UNIX only, sorted the
- directory by name (because in UNIX, we have access to the list pointer).
- ckcfns.c, ckermit2.txt, 28 Jan 99.
- Fixed server end of REMOTE DIRECTORY to be compatible with local directory
- listing format -- no more "<DIR>" in UNIX, show symlinks, don't always
- show full pathname (but do show it in headings). ckcfns.c, 29 Jan 99.
- Changed date-time string shown in directory listings when actual date/time
- can't be obtained from ????-??-?? ??:??:?? to 0000-00-00 00:00:00, so as
- not to put non-digits in numeric fields. ckcfns.c, ckuus6.c, 29 Jan 99.
- "remote directory | sort -r" was sending "| sort -r" as the filespec
- to the server, oops. However, "remote directory | sort -r > foo" works as
- expected. This was a bug in remtxt(), fixed in ckuus7.c, 29 Jan 99. Now we
- can pipe incoming directory listings through local filters for display on
- the screen, e.g. to sort in reverse chronological order, etc. Documented
- this in ckermit2.txt Section 5.3.2.
- The C-Kermit server drops a character from the directory listing at the end of
- each packet, as you can easily see by restricting the packet length to (say)
- 30 (it's not quite so obvious when the packet length is 8000). But it's not
- nxtdir()'s fault, because nxtdir() returns every character from the listing.
- In fact, sdata() is being called with a length that is 1 less than the actual
- number of characters obtained from nxdir(). This problem has nothing to do
- with recent changes to REMOTE DIRECTORY since REMOTE TYPE has the same
- problem, and also REMOTE DELETE, REMOTE HELP, and any other command
- implemented by sndblah()/nxtblah(). In fact, it's been there for quite some
- time. But it doesn't happen in regular file transfer, so what's the
- difference? ... Aha, it's in getpkt() -- the manipulation of the "first" flag
- (governing lookahead and EOF) was not totally copied from the input-from-file
- case to the input-from-function and other cases. Fixed in getpkt(), ckcfns.c,
- 29 Jan 99.
- From Jeff: Command interface for KLOGIN and EKLOGIN:
- RLOGIN /ENCRYPT /KERBEROS <host> <userid> <protocol>.
- ckuusr.h ckuus5.c ckuus7.c ckcnet.h ckcnet.c, 29 Jan 99.
- Found some places where the connection log was not being written, namely
- in the TELNET and RLOGIN commands. Fixed in ckuus[3r].c, 29 Jan 99.
- The confusion between CLOSE CONNECTION and CLOSE CONNECTION-LOG was just too
- dangerous, so even though it's ugly, I changed the name of the connection log
- to "CX log": LOG CX, CLOSE CX[-LOG]. ckuus[r2].c, 29 Jan 99.
- From Jeff: Internal Telnet reset function. ckctel.[ch], ckcnet.c, 30 Jan 99.
- Due to a typo, the key in DIR /SORT:key was sticky. Fixed in domydir(),
- ckuus6.c, 30 Jan 99.
- Discovered that IKSD could be suspended with SUSPEND or Z command (but not
- with Ctrl-Z). SUSPEND/Z also worked when nopush was in effect. Fixed in
- ckuusr.c, 30 Jan 99.
- Discovered that if you gave a DIRECTORY command to IKSD in a directory that
- can't be read, it would say "?Read permission denied - xxx" where xxx was
- a filename. Changed cmifi() to not show the filename under these conditions.
- ckucmd.c, 30 Jan 99.
- PRINT command given by IKSD guest gave the wrong error message. ckuusr.c,
- 30 Jan 99.
- RECEIVE, given by IKSD guest in directory to which it does not have write
- access works when it shouldn't. But then of course it stops when it goes to
- write out the first bufferful -- the file is not actually created. But now
- there is about 32K of packets in the pipeline, and all sorts of confusion
- ensues, especially when streaming. Fixed rcvfil() to precheck write
- accessibility before accepting the file. ckcfns.c, 30 Jan 99.
- MOVE, SEND /MOVE, etc, were allowed by IKSD to guest users; they did indeed
- send the file, but did not delete it. Still, it should not give the
- impression that it worked, so a check was added. ckuusr.c, 30 Jan 99.
- Horizontal-line printing was needed to move to left margin first when
- returning from CONNECT mode due to autodownload or APC. ckucns.c, ck[uv]con.c,
- 30 Jan 99.
- Traverse() test:
- dir
- dir /files
- dir /directories
- dir /recursive
- dir /recursive /files
- dir /recursive /directories
- dir oofa.txt
- dir /recursive oofa.txt
- dir /recursive *.txt
- dir *.txt
- dir */*.txt
- dir */*/*.txt
- dir .*
- dir /recursive .*
- dir /dotfiles
- dir /dotfiles /recursive
- dir foo (where "foo" is a relative directory name)
- dir .
- dir ..
- dir /fullpathname (of a directory)
- dir /fullpathname (of a file)
- dir /fullpathname (of filename with wildcards)
- dir /fullpathname (with wildcards in path)
- dir /files /fullpathname
- dir /directories /fullpathname
- All the above work. The following still try to read the entire file
- system. Will fix in next Beta:
- dir /recursive /fullpathname (of a directory)
- dir /recursive /fullpathname (of a file)
- dir /recursive /fullpathname (of filename with wildcards)
- dir /recursive /fullpathname (with wildcards in path)
- dir /recursive /files /fullpathname
- dir /recursive /directories /fullpathname
- Add -funsigned-char to sunos41gcc and solaris25g makefile entries. makefile,
- 30 Jan 99.
- Numerous #ifdef, syntax, and declaration adjustments when building on many
- platforms with different options sets. Many modules, 30-31 Jan 99.
- initopts() was dumping core on some platforms -- char pointers not init'd
- to NULL before calling makestr() on them. ckuus5.c, 31 Jan 99.
- --- Beta.04 ---
- From Jeff: command interface for RLOGIN /K4 /K5 /ENCRYPT; rlogin (except for
- window size) is working again on Unix; rlogin /k4 (except for window size) is
- now working on Unix (no root required). ckuusr.h ckuus7.c ckuus5.c ckcnet.c
- ckcnet.h ckctel.c ckctel.h ckuath.h ckuat2.h ckuath.c ck_crp.c, 1 Feb 99.
- Server side remote directory file lister didn't have enough %s's in format
- string for non-perms case. ckcfns.c, 1 Feb 99.
- Fixed some long lines in ckuus2.c, 1 Feb 99.
- The HP-UX 5.00 Wollongong TCP/IP build suddenly stopped working because
- of complaints about inet_addr(), e.g.
- "ckcnet.c", line 3411: operands of = have incompatible types
- where line 3411 is:
- saddr.sin_addr.s_addr = inet_addr(tcp_address);
- inet_addr() can NEVER NEVER NEVER be used without including the #ifdef INADDRX
- code around it. Evidently a lot of calls to inet_addr() were added since
- Beta.02, which is the last time I built on this system. This means that
- builds that use INADDRX won't work. Unfortunately this is the only platform I
- have access to that needs it, and it can be accessed only by special
- arrangement, since it is normally kept turned off, and every compilation takes
- several hours. Fixed in ckcnet.c, 2 Feb 99. Fortunately this is not a
- show-stopper for Beta.04, since only very old UNIX versions need this, like
- Integrated Solutions Inc V8S VME 68020 and Motorola Delta System V/68 R3V5.
- Added an hpux500 makefile entry (no net). 2 Feb 99.
- Although ckutio.c does not reference bzero(), somehow it is being referenced
- from the generated object file (nm ckutio.o | grep bzero) in HPUX 5.00.
- So I added a bzero stub to ckutio.c only for HPUX 5.00, only for the no-net
- build. 2 Feb 99. (Later it turned out that a macro defines memcpy or memset
- as bzero somewhere...)
- Removed references to INADDRX for DG/UX from makefile and ckcnet.h. 2 Feb 99.
- More from Jeff on Kerberized Rlogin. ckcnet.[ch], ckuus[47], etc, 2 Feb 99.
- From Jeff: Fix a bug in which return value of ckgetpeer() was not checked for
- NULL when writing wtmp record, causing IKSD to crash when accessed by a host
- that could not be found in DNS. And fix ckgetpeer() itself to return the
- peer's IP address if it can't get the name. ckufio.c, ckcnet.c, 4 Feb 99.
- Fix from Jeff for draining problem. ckcfn2.c, ckctel.c, 6 Feb 99.
- For some weeks now there has been a problem with the VMS UCX version: when
- sending files on a TCP/IP connection with streaming, the transfer gets stuck
- after sending the EOF (Z) packet; the Z packet is sent OK, but C-Kermit never
- reads the ACK. Ctrl-C'ing out and CONNECTing back reveals the ACK still
- sitting there waiting to be read. And yet: (a) This does not happen in
- non-UCX VMS versions or in UNIX versions; (b) it does not happen in the UCX
- version when the debug log is turned on. The problem was traced to netinc();
- it seemed that once select() failed, it would never succeed again. Jeff
- guessed that a failing select() in UCX (and who knows where else) might alter
- its parameters ("help cc socket_routines select" was uninformative), and that
- moving the select() initialization (FD_ZERO(), FD_SET() into the for-loop
- would fix the problem, and indeed that seems to have done the trick.
- ckcnet.c, 7 Feb 99.
- UNIX C-Kermit was failing to send the first byte of each file (or actually,
- the first byte of each 32K bufferful read from disk) due to a typo in a debug
- statement I added to zinfill() after Beta.04 was released. Fixed in ckufio.c,
- 7 Feb 99.
- From Lucas Hart: Fixed osf makefile entry to pass CC and CC2 values along,
- and add a du40gcc tarket. makefile, 7 Feb 99.
- Fixed various minor syntactic warnings from gcc on DU 4.0. ckcfn2.c,
- ckuus[rx].c, 7 Feb 99.
- Another mysterious problem... After releasing Beta.04, I finally was able to
- build on AIX 4.1, but discovered that it had suddenly and for no apparent
- reason started exhibiting the "terminal buffering reset after using curses"
- problem, so that characters typed at the prompt would not echo until Return
- was pressed, even though concb() had been been called to put the console back
- in CBREAK mode. This did not happen on earlier C-Kermit builds on AIX 4.1,
- nor does it happen in the current build on AIX 4.2 or 4.3, nor, as far as I
- can tell, on any other platform either. The classic remedy to this problem is
- to use newterm() rather than initscr() to initialize curses, accomplished by
- adding -DCK_NEWTERM to the makefile entry. This seems to have fixed the
- problem. I wonder if this means the same should be done in later AIX
- versions, even though we presently have no adverse symptoms. makefile,
- 8 Feb 99.
- Jeff pointed out that the server does not set the success flag internally
- when it executes a command that generates a short-form response. Fixed in
- ckcpro.w, 8 Feb 99.
- IKSD was improperly calling syscmd() to check disk space (of course, it didn't
- work, but it was acting like it did -- returning an empty report rather than
- an error). Unfortunately, there is no good way to internalize disk-space
- checking code in UNIX since the methods for doing so are COMPLETELY unportable
- (and unreliable), so I made the server return an appropriate error when given
- a REMOTE SPACE command and nopush is effective. ckcpro.w, 8 Feb 99.
- There were a few lingering problems with directory-tree recursion. As noted
- above, "dir /recursive /xxx", where /xxx was any full path (i.e. starting with
- slash), would appear to hang because it was reading the whole file system.
- Also "dir /recursive .." did not work at all. Also "dir /recursive ." gave
- incomplete results. These were fixed by slightly altering the decision about
- whether to recurse in UNIX traverse(), without breaking anything else, except
- "dir /recursive blah" (where blah is a filename with no wildcards); this was
- fixed by adding one more condition to the same decision. Now we seem to pass
- all tests. ckufio.c, 8 Feb 99.
- Changed sinix543 makefile target to sni543, and added sni544. SNI says the
- name SINIX was dropped after 5.42 in favor of Reliant UNIX. makefile,
- ckuver.h, 8 Feb 99.
- Added Ctrl-Z (and ^Z+0x80) to SET PREFIXING CAUTIOUS to accommodate
- connections to UNIX hosts that have old versions of C-Kermit that don't know
- how to disable SIGTSTOP. ckcmai.c, 8 Feb 99.
- v(lockdir) lopped off the final character of the directory name on some
- systems (e.g. Linux) but not others. Fixed in nvlook(), ckuus4.c, 8 Feb 99.
- Fixed ckutio.c (again) to use the right #ifdef around gettimeofday().
- 9 Feb 99.
- Removed -K option from sni54[34] entries, where it is no longer valid.
- makefile, 9 Feb 99.
- Fixed local SPACE command to error out if nopush and an external command or
- program is required. ckuusr.c, 9 Feb 99.
- Added -DK_NEWTERM to the Linux target, in response to a rash of complaints
- about loss of CBREAK mode on tty after curses display. Did NOT add this to
- the AIX 4.2 and 4.3 entries, even though it was suddenly necessary for 4.1,
- since trials on 4.2 and 4.3 show that it completely hangs the program.
- makefile, 9 Feb 99.
- From Jeff: Preserve user ID and Password around failed SET HOST, TELNET,
- and RLOGIN parses. ckuus7.c, 9 Feb 99.
- Another correction for #ifdefs around gettimeofday(). ckutio.c, 10 Feb 99.
- Built for the first time on VMS 7.2, and with UCX 5.0, and with TGV 4.2A, and
- with DECC 6.0, and miraculously no source changes were needed. 10 Feb 99.
- Changes from Jeff for Windows-95-specific SET WIN95 items and help text,
- including new SET WIN95 8.3-FILENAMES { ON, OFF }. ckuusr.h, ckuus[27].c,
- 10 Feb 99.
- Added some casts to suppress warnings about pointers not assignment compatible
- (signed vs unsigned char). ckcfn2.c, ckcnet.c, 10 Feb 99.
- Folded long lines in ckuath.c, 10 Feb 99.
- Added a missing #ifndef NOSERVER..#endif clause to some code in ckcfn3.c.
- 10 Feb 99.
- Simplified UNIX traverse() to eliminate some redundant function calls.
- ckufio.c, 10 Feb 99.
- Spent some more time with UNIX traverse() to see why it's skipping some files
- it should pick up in some cases, but made little progress. To be continued.
- ckufio.c, 10 Feb 99.
- Fixes for DG/UX: add declaration for tv, tz to ckutio.c; add NOGETUSERSHELL
- and CK_NEWTERM to, and remove CK_POLL from, makefile entries. 11 Feb 99.
- Verified that SINIX 5.42 does not need CK_NEWTERM. 11 Feb 99.
- Mark Berryman said that "u_int" errors go away in UCX 5.0 builds if you
- #include <if.h>. This works great in UCX 5.0, but UCX 2.0 has no <if.h>.
- There is also a warning about the data type of the length argument to
- getpeername. It needs to be unsigned int in UCX 5.0, but signed in previous
- versions. We need to (a) find a UCX-5.0-unique symbol in the UCX header
- files, or (b) a logical name or symbol we can pick up in the DCL build
- procedure, or (c) create a new build target or somesuch. 11 Feb 99.
- Back to UNIX traverse. After yesterday's changes, we now pass all tests with
- the following exceptions:
- 1. "dir /recu <filename>" shows directory names as well names of files
- that match <filename>, which might or might not be wild.
- 2. "dir /recu /tmp" skips most files and directories in /tmp.
- This last one is quite odd, since the same commands work fine in other
- directories on the testbed system. What's different about /tmp?
- Added zrewind() to ckufio.c. Rationale: DIRECTORY calls cmifi(), which
- calls zxpand to expand the file list. If this succeeds, then DIRECTORY itself
- calls zxpand again. But as long as the same argument and criteria are used
- each time, the second call should be unnecessary -- all we need to do is
- use the list from the first time, which is still there. zrewind() resets the
- list pointer to the beginning and returns the count. Obviously this is for
- UNIX only, since other implementations do not necessarily create an internal
- list. But when it can be used, it cuts the time in half -- quite noticeable
- in long directories. ckuus[56].c, ckufio.c, 11 Feb 99.
- And of course it also makes debugging easier since we only have one invocation
- of zxpand to deal with... OK, so back to traverse....
- Hmmm... traverse() knows whether a file is a directory when it calls
- addresult() to put it on the list. But then addresult() calls isdir() again
- to find out if its argument a directory. Added a second parameter to
- addresult() to let the caller tell it in advance whether it's a directory, or
- if it must be looked up. This eliminates lots of redundant stat() calls and
- speeds things up even more. After this, and after cleaning up traverse() line
- by line, it all seems to work except for a couple minor glitches that I can
- clean up tomorrow. ckufio.c, 11 Feb 99.
- With hints from Mark Berryman, added autodetection of UCX 5.0 to CKVKER.COM;
- if detected, it adds UCX50 to CFLAGS. The issue here is that <if.h> must be
- included in UCX 5.0 to pick up the definition of u_int (and who knows what
- else), but it does not exist in earlier releases. Corresponding #ifdefs in
- the code take care of the special considerations in the modules. Now C-Kermit
- builds without complaint and without any special CKVKER.COM command-line
- invocation on UXC 2.0, 4.0, and 5.0 as well as on TGV 4.0. ckvker.com,
- ckcnet.[ch], ckuus[45].c, 12 Feb 99.
- Fixed the following problem noticed by Jeff: if protocol is XMODEM, then
- RECEIVE /PROTO:KERMIT gives an error if an as-name was not specified.
- doxget(), ckuus6.c, 12 Feb 99.
- Changed the name of zrewind() to zxrewind() to make it look more like a friend
- of zxpand() and not an analog of rewind(), which resets a file pointer, and
- which we might want to add later for some reason. Added a symbol that says
- whether we can use it, ZXREWIND, and defined it for K95 and UNIX, since Jeff
- added it for K95. Changed all calls to zxrewind() to be in #ifdef
- ZXREWIND..#endif. ckcdeb.h, ckufio.c, ckuus[56].c, ckcplm.txt, 12 Feb 99.
- In several spots in cmifi(), zxpand() was called a second time to rewind the
- file list; replaced these calls with zxrewind(). ckucmd.c, 12 Feb 99.
- Ditto in the spot in fneval() where zxpand() was called to rewind the list
- in K95. ckuus4.c, 12 Feb 99.
- Corrections from Jeff to yesterday's changes, plus new IF AVAILABLE options
- for encryption, SSL, SRP, NTLM, etc, plus a couple =='s that should should've
- been ='s. Changed AVAIL_blah to AV_blah since macros must be unique within 8
- chars in some cpp's. ckcpro.w, ckucmd.c, ckuus[26].c, 13 Feb 99.
- Some debug() statements fixed by Lucas Hart, especially one in a VMS section
- of domydir() that referenced a pointer that had not yet been init'd. ckuus6.c,
- 13 Feb 99.
- From Lucas Hart: fix for VMS isdir() to recognize a search list as a directory
- so (e.g.) "cd sys$manager" can work. ckvfio.c, 13 Feb 99.
- Added zxrewind() for VMS. ckcdeb.h (define ZXREWIND for VMS), ckvfio.c,
- 13 Feb 99.
- Hit upon an idea to make /RECURSIVE work for VMS: in fgen(), before the
- lib$find_file() loop, call zfnqfp() to get the full filespec including
- directory brackets, then insert "..." before the closing bracket IF (a)
- "recursive" was set, (b) the argument filespec did not already contain "...",
- and (c) there actually was a closing directory bracket. Checked first to see
- if LIB$FIND_FILE() itself had an option for recursive searching; it doesn't.
- This fully enables SEND /RECURSIVE and DIR /RECURSIVE, plus GET /RECURSIVE
- when send to a VMS C-Kermit server, without the user having to include "..."
- in filespecs, and eliminates lots of "buts" and "excepts" in the documentaion.
- ckcdeb.h (define RECURSIVE for VMS), ckvfio.c, ckermit2.txt, 13 Feb 99.
- "dir blah" in VMS did nothing if BLAH.DIR;1 is a directory. It should do the
- same as "dir [.blah]". Cause: failure to reset fcount in zxrewind; fixed in
- ckvfio.c and ckufio.c, 13 Feb 99.
- Lucas said that in VMS, "dir foo.dir" should just list the FOO.DIR file,
- rather than the files in [.FOO], as it currently does. Whereas (I think) "dir
- foo" and "dir [.foo]" should list the contents of the directory rather than
- the directory file itself, as they do now, and as "dir foo" (where foo is a
- directory name) does in UNIX and K95. Added code to cmifi() to make this
- distinction. Now "dir [/recursive] foo.dir" (or *.dir, etc) lists directory
- files; the others list contents. The FOO.DIR -> [.FOO] conversion is skipped
- only when the DIRECTORY command is active, because we need this conversion
- at other times. ckucmd.c, ckermit2.txt, 13 Feb 99.
- On a similar note, there is no way in UNIX to obtain the "ls -d" behavior,
- i.e. to list a specified directory file, rather than the files in the
- directory. We'll return to this later...
- Back to UNIX traverse()... "dir /recursive oofa.txt" lists not only all
- oofa.txt files in the current directory tree, but also each directory that
- contains an oofa.txt file; example:
- (/w/fdc/tree/) C-Kermit>dir /rec oofa.txt
- drwxrwx--- 512 1999-01-28 16:53:59 subdir/another/ <--
- -rw-rw---- 6067 1999-01-07 21:21:43 subdir/another/oofa.txt
- -rw-rw---- 3537 1999-01-12 18:07:46 subdir/oofa.txt
- drwxrwx--- 512 1999-01-12 20:18:15 subdir/thisdir/ <--
- -rw-rw---- 6067 1999-01-12 16:00:42 subdir/thisdir/oofa.txt
- -rw-rw---- 2192 1999-01-13 11:03:14 oofa.txt
- (/w/fdc/tree/) C-Kermit>
- It should only list the files themselves; the entries marked by arrows should
- not appear. Of course, including the /FILES switch produces the desired
- result. Also, "dir /rec *.txt" does not show this problem. So that means
- it only happens when the original filespec was wild. So don't add a directory
- name to the list when recursing if the original filespec was not wild.
- ckufio.c, 13 Feb 99.
- Next: directories whose names start with "." should not be opened if matchdot
- is 0 and if the "." was not specified in the user's pattern. Fixed by adding
- another test to traverse(). ckufio.c, 13 Feb 99.
- Next: "dir /recursive */*.txt" lists all files in the current directory, even
- if they don't match "*.txt", but correctly selects only *.txt files in lower
- directories. Changed a comparison. ckufio.c, 13 Feb 99.
- Next: "dir .*" doesn't list dotfiles anymore unless /DOTFILES included. Added
- another test. ckufio.c, 13 Feb 99.
- Now UNIX C-Kermit passes all "traverse.txt" tests in its local DIR command.
- After yesterday's changes, plain old "dir" in VMS acted recursively due to
- missing parens in a while condition; fixed in cmifi(). ckucmd.c, 14 Feb 99.
- Now the VMS version passes all tests.
- Changed VMS zgetfs() to call stat() to get file size and directory status,
- since it can succeed where RMS fails, e.g. when permissions don't allow
- opening. This removes lots of nasty -1's from the directory listing.
- However, permissions are still lost when the file can't be opened. ckvfio.c,
- ckcfns.c, ckuus6.c, 14 Feb 99.
- UNIX C-Kermit server's directory listings sent to client did not handle
- symlinks. Fixed in nxtdir(). ckucmd.c, 14 Feb 99.
- Minor updates from Nigel Roles for Plan 9. ckucmd.h, ckufio.c, ckpker.mk,
- 14 Feb 99.
- Jeff renamed os2_setflow() to ttsetflow(). ckudia.c, ckuus6.c, 15 Feb 99.
- Updated HELP SET NETWORK text. ckuus2.c, 15 Feb 99.
- Faced up to the fact the having a single variable for flow control is an idea
- whose time is past. Added a connection-type switch for SET FLOW, so now SET
- FLOW can take an optional switch (/REMOTE, /TCPIP, /MODEM, etc) to set the
- default flow control for a particular type of connection without affecting the
- others. Added a flow control table with appropriate flow values for each type
- of connection. Added SHOW FLOW to show the table plus the current flow
- control. Got rid of SET FLOW AUTO, since now it's meaningless (the command is
- still accepted, but does nothing). Now you can flip around among different
- kinds of connections and get the right kind of flow control without thinking
- about it (usually). NOTE: At first I thought the best default for remote mode
- would be KEEP, but that doesn't work at all when coming in via Telnet -- it
- totally wrecks file transfer. So for now, at least, it's NONE. ckcdeb.h,
- ckuusr.h, ckcmai.c, ckuus*.c, ckermit2.txt, 15 Feb 99.
- Setting SIGINT and SIGQUIT to SIG_IGN was left out of the ckucon-to-ckucns
- transition. It didn't matter in most cases, since ttvt() puts the console
- into raw mode, but in HP-UX, the HP-9000 <RESET> key still raises SIGINT,
- which under these conditions kills C-Kermit when hit twice. So the
- appropriate signal() calls were added to conect() after the ttvt() call.
- ckucns.c, 15 Feb 99.
- Added SHOW TRANSFER (XFER) to SHOW all the SET TRANSFER items. ckuusr.h,
- ckuus4.c, 15 Feb 99.
- Filled in new and missing SET TRANSFER items in HELP SET TRANSFER text.
- ckuus2.c, 15 Feb 99.
- Added missing zxrewind() prototype to ckcdeb.h. 15 Feb 99.
- Noticed that if I give a TYPE command at the IKSD> prompt, and the file
- contains any 0xff bytes, these are sent bare, thus forming a random Telnet
- command for the client Changed the TYPE command to double 0xff characters if
- (sstelnet || inserver). ckuus6.c, 15 Feb 99. There are probably other places
- where this could happen...
- Added a tgetent() stub for VOS. ckuusx.c, 15 Feb 99.
- In VMS, we use zrelname() to reduce a fully qualified filespec to a relative
- one, to save space in the directory listing. Thus if my current directory is
- D0:[FDC] and I say "dir [fdc.text]oofa.txt", it will print "[.TEXT]OOFA.TXT"
- instead of "DISK0:[FDC.TEXT]OOFA.TXT". However, if my current directory is
- [FDC.TEXT] and I say "dir [-]login.com", it prints "[.TEXT]LOGIN.COM" instead
- of "[FDC]LOGIN.COM" or "[-]LOGIN.COM". So zrelname() was fixed to take into
- account the case where the current directory is a subdirectory (one or more
- levels down) of the file's directory, in which case it prints [-] or [--],
- etc, for the file's directory. ckvfio.c, 15 Feb 99.
- From Jeff: some #ifdef adjustments to prevent undefined auth/crypt symbols:
- ckuus6.c; some auth/crypt changes to ckcnet.c and ckuath.c; debugging
- statements added to ckcfn2.c packet/checksum routines. 16 Feb 99.
- From Jeff: initialize lots of automatic variables in functions all over the
- place. Many modules, 16 Feb 99.
- Back to zrelname() in VMS. There were some glitches, plus it did not handle
- the case where the file directory is not a subdirectory of the current
- directory, nor vice versa, but the two shared a common ancestor. ckvfio.c,
- 16 Feb 99.
- Various (CHAR *) / (char *) casts. ckcfns.c, ckcnet.c, 17 Feb 99.
- The "dironly" and "fileonly" hacks have become unbearable. A piece of code
- such as domydir() can set or unset them prior to calling (say) zxpand() or
- cmifi(), but loses control the minute the called routine does the same, or
- calls some other routine that might do the same. So I added a new API:
- nzxpand(s,flags), which is zxpand() with a second argument: flags == 1 means
- files only; 2 means directories only; anything else (normally 0 or 3) means
- files and directories. I brutally expunged all references to the dironly and
- fileonly variables from all files, and replaced all zxpand() calls in the
- mainline code with nzxpand() (this won't break weird platforms -- see
- ckcdeb.h). I think everything will work much better now. ck[duv]fio.c,
- ckvfio.c, ckucmd.c, ckuus6.c, ckcdeb.h, ckcplm.txt, 17 Feb 99.
- Some corrections from Jeff to yesterday's changes. ckcdeb.h, ckuusy.c,
- ckufio.c, 18 Feb 99.
- Added zrewind() for AOS/VS. ckcdeb.h, ckdfio.c, 18 Feb 99.
- Changed nzxpand() to be totally parameter-driven; flags word now contains
- flags for dironly, fileonly, matchdot, recursive, etc. ckcdeb.h, ckcfns.c,
- ckcpro.w, ck[duv]fio.c, ckucmd.c, ckuus[46y].c, 18 Feb 99.
- Added NOXFER symbol, which, if defined, deselects all file-transfer code
- (Kermit and XYZMODEM) at compile time. This is for building C-Kermit strictly
- as a scripting and communications engine, when memory is at a premium, e.g. in
- Linux-based embedded systems. -DNOXFER removes about 300K on Intel, 400K on
- Sparc. All modules changed with very few exceptions. Built OK with and
- without -DNOXFER on UNIX and VMS. Added a "linuxso" target for building a
- < 400K version that includes full scripting and serial communications, but
- no networks, help, character-sets, etc, that would not be used in a typical
- embedded application. 18 Feb 99.
- Added autodetection of <if.h> to CKVKER.COM for picking up u_int in UCX
- versions below 5.0. 19 Feb 99.
- A user noted a limit of 1024 on array size -- this was a totally arbitrary
- and needless restriction, so I removed it. Now an array can be any size
- at all (until and unless a malloc() fails). ckuusr.c, 21 Feb 99.
- Changed UNIX version to not set BRKINT -- I have no idea why it ever did.
- This causes big problems with UNIX workstations that have a BREAK key,
- especially if it is badly positioned (as on HP keyboards, where users hit it
- accidentally while trying to type Esc). ckutio.c, 21 Feb 99.
- UNIX "send ./?" was listing dot files when it shouldn't. Fixed in traverse().
- ckufio.c, 21 Feb 99.
- Fixed some more CHAR/char complaints. ckuus6.c, 22 Feb 99.
- CD command makes disk spin if <ESC> typed in the middle of a directory name,
- whereas Beta.04 didn't do this. This is because traverse now calls isdir() on
- every file. Fixed this by calling isdir() only when we know we have to.
- traverse(), ckufio.c, 22 Feb 99.
- Discovered that SEND /RECURSIVE *to* C-Kermit no longer works: zchko() says
- access denied. I'm not sure how or when this happened, but the problem was
- that when we check writeability of nonexistent paths, access() fails. zchko()
- needed to be changed to peel back path segments until we reached one that
- existed before calling access on it. (If we can create a file in an existing
- directory, then we can also create a directory, and in fact a whole tree.)
- ckufio.c, 22 Feb 99.
- Discovered that the following sequence:
- cd subdir, dir .., cd .., dir /recu /dir .
- gives a bizarre listing. It turns out that cmifi() skipped calling nzxpand()
- in this case, and so zxrewind gave us the list from *previous* call, which is
- of course no longer valid in the new context, so zgetfs() and friends all
- fail. Fixed in cmifi2() by ensuring it ALWAYS calls nzxpand() (at least when
- diractive is nonzero). ckucmd.c, 22 Feb 99.
- Discovered that "dir /recursive /tmp/fdc/foo" (i.e. a full absolute path
- containing no wildcards) takes forever because traverse reads the whole file
- system. Of course this was fixed several times before, but then subsequent
- fixes (specifically, for "dir /recursive foo.bar" -- same thing, but path
- NOT absolute) broke it. Fixed in traverse(), ckufio.c, 22 Feb 99. The
- /RECURSIVE switch is ignored in this case, which makes C-Kermit do the same
- thing as "ls -lR /tmp/fdc/foo".
- Peter Eichhorn tested yesterday's code in a directory that contained 10,000
- files: "ck abc<ESC>" still took forever and made the disk spin a lot. It
- turns out the change I made yesterday also needed to be made in another place.
- Now it's fast again. ckufio.c, 23 Feb 99.
- Added -DNOTTYLOCK to AIX 3.x targets, since ttylock() evidently does not work
- right there (the code compiles OK but says "access to lock denied", even
- though it has all the same perms and owner/group as cu, whereas if built to
- use do-it-yourself lockfile handling, it works OK). makefile, 23 Feb 99.
- Problem: We have (say) a UNIX-to-UNIX connection with all defaults,
- client/server. We say "get blah.txt". The file is sent in text mode because
- of the "*.txt" pattern, but the transfer is interrupted. So then later we say
- "reget blah.txt". This is refused because the "*.txt" pattern puts it into
- text mode again and REGET must be in binary mode. Two problems:
- 1. The file did not have to be sent in text mode in the first place if
- C-Kermit had recognized that the connection was between "like systems"
- AND character-set translation was not active. In this case, we can skip
- looking thru the patterns and just stick with binary mode.
- 2. [RE]GET /BINARY did not work when the filename matched a text pattern on
- the server side. Fixing this required defining a new transfer-mode
- WHATAMI bit for the initialization string, but since the WHATAMI field was
- already full, a new WHATAMI2 field was added. Now GET /BINARY, REGET
- /BINARY, GET /TEXT, etc, always work exactly as expected. ckcker.h,
- ckcpro.w, ckcfns.c, ckuus[r6].c, ckermit2.txt, 24 Feb 99.
- These (and the next two) are rather fundamental changes and need a pretty
- heavy workout.
- Made RESEND and SEND /RECOVER both imply /BINARY since they won't work any
- other way. ckuusr.c, ckermit2.txt, 24 Feb 99.
- Ditto for REGET and GET /RECOVER. This, in turn, forces manual transfer mode
- at the server, and now even "reget oofa.txt" will work, at least assuming
- client and server have compatible (i.e. non-length-changing) text-file
- formats. ckuus6.c, ckermit2.txt, 24 Feb 99.
- Added SEND /[NO]DOTFILES. ckuusr.h, ckuus[r2].c, ckermit2.txt, 24 Feb 99.
- Discovered SHOW FILE wasn't working right. Diagnosis: feol was declared as
- extern int rather than extern CHAR. Fixed in ckuus4.c, 24 Feb 99.
- Added dynixptx216c target to makefile, from Roger Allen. 24 Feb 99.
- Made "cop" be an OK abbreviation for "copy". ckuusr.c, 24 Feb 99.
- Changes from Jeff for K95G. ckuus[7x].c, 24 Feb 99.
- Updated sunos41gcc+krb and +srp makefile entries from Jeff. 25 Feb 99.
- The CD Message was fractured in IKSD -- forgot to add a terminating NUL at
- the end of the string when making the IAC-doubled copy. ckuus6.c, 25 Feb 99.
- Promptly removed the aforementioned code because it really belongs in the
- printf (puts, putc, etc) substitute that we are already using for server-side
- telnet and IKSD. ckuus6.c, 25 Feb 99.
- From Jeff, 25 Feb 99:
- . IAC doubling added to ckxprintf() and ckxfprintf(). ckcdeb.h, ckutio.c.
- . Check for stdout/stderr in ckxfprintf(). ckutio.c.
- . Removed commented-out IAC doubling from dotype(). ckuus6.c.
- . Moved allocation of keymap/macro from cmdini() to before sysinit() for
- the benefit of K95G which starts being delivered keyboard input during
- sysinit(). ckcmai.c, ckuus5.c.
- Added encryption indication to SHOW CONNECTION. ckuus3.c, 25 Feb 99.
- Peter E reported that transfers between two Kermit programs failed when there
- was an Rlogin command between them and C-Kermit 7.0 was the file sender, but
- such transfers did not fail in earlier releases. Diagnosis: C-Kermit 7.0
- unprefixes <LF> by default; if a packet contains "<LF>~." this breaks the
- Rlogin connection. Packets contain this sequence when a file has a line that
- begins with 14 repeated characters. Since Kermit has no way of knowing there
- is an Rlogin command in the middle, we have to prefix LF by default.
- ckcmai.c, 25 Feb 99. (Ditto when 'cu' is in the middle.)
- Peter E also noticed that C-Kermit would crash under certain conditions on
- some versions of HP-UX when its debug log was active during file transfer. It
- looks like the debug(F011,...) handler did not allocate quite enough memory
- when given a really long string (like 32K). Fixed in dodebug(), ckuusx.c.
- Also, the "debug(F011,"ZINFILL fread",zinbuffer,zincnt);" call was overkill
- anyway since now we're reading 32K chunks from the disk. Changed it to just
- show the count; ckufio.c, 25 Feb 99.
- Minor syntactic corrections to yesterday's changes. ckuus3.c, ckutio.c,
- 26 Feb 99.
- Changed C-Kermit's default file type from text to binary. ckcmai.c,
- ckermit2.txt (Sections 0, 4, and 4.3), 26 Feb 99.
- Renamed hpux90mot target to hpux90m68ko for consistency. "-funsigned-char"
- added to CFLAGS of all HP-UX gcc targets. makefile, 26 Feb 99.
- When making SEND /RECOVER imply /BINARY, I accidentally also made
- SEND /RECURSIVE imply /BINARY. Fixed in doxsend(), ckuusr.c, 26 Feb 99.
- Back to client/server conveniences... Client SEND /RECURSIVE does not
- automatically SET RECEIVE PATHNAMES RELATIVE in the server, but GET /RECURSIVE
- does. Why is this? Because GET /RECURSIVE uses a special packet type but
- SEND /RECURSIVE does not. The user should not have to deal with this. Added
- PATH_AUTO to ckcker.h. Added SET RECEIVE PATHNAMES AUTO: ckuus7.c. Made AUTO
- be the RECEIVE PATHNAMES default: ckcmai.c. Fixed SHOW FILE to display the
- new value: ckuus4.c. Defined a WMI2_RECU bit for the new WHATAMI2 field:
- ckcker.h. Set this bit in rpar() if recursive > 0, and set RECEIVE PATHNAMES
- to RELATIVE automatically in spar() if RECEIVE PATHNAMES was AUTO, plus set a
- flag this was done so AUTO would be restored at the end of the transaction or
- upon interruption: ckcfns.c, ckuus[25x].c, ckermit2.txt, 26 Feb 99.
- Fix to cmifi() from Jeff to make sure it calls nzxpand() in K95 even if
- user gives only a disk letter. ckucmd.c, 26 Feb 99.
- Fixes from Jeff to DIR /ENGLISHDATE and Rlogin problems reported by Lucas
- Hart. ckuus[67].c, 28 Feb 99.
- Jeff suggested we keep incomplete files only when receiving in binary mode.
- Added [ REMOTE ] SET [ FILE ] INCOMPLETE AUTO, which means KEEP when in binary
- mode, DISCARD otherwise. ckuus[2346].c, ckcfn[s3].c, ckcmai.c, ckcpro.w,
- ckermit2.txt, 28 Feb 99.
- The change I made on 24 Feb to use binary mode whenever the two Kermits are
- on like platforms and there was no charset translation was broken by setting
- the default file type to binary. Fixed in sfile(): ckcfns.c, 28 Feb 99.
- Added /MOVE-TO: and /RENAME-TO: switches, which were already available for
- SEND, to GET and RECEIVE. This rounds out our "atomic file movement"
- repertoire. ckcmai.c, ckuus[56x].c, ckcfns.c, 28 Feb 99.
- Numerous corrections to internal crossrefs in ckermit2.txt from Peter E.
- 28 Feb 99.
- Got rid of the long and hideous mass of #ifdefs around the tv and tz
- declarations in ckutio.c by adding NOTIMEZONE / HAVE_TZ and NOTIMEVAL /
- HAVE_TV symbols to ckcdeb.h. 1 Mar 99.
- Moved call to fxdinit() (fullscreen file-transfer display initialization) from
- main() to screen(), and ensured we don't call it unless we have to, we don't
- execute it more than once, and we don't print any error messages when in
- background or batch. This fixes numerous problems; e.g. the screen was a
- total shambles before if the terminal type was unknown, pointless warnings
- about terminal type when the file transfer display would not have been
- fullscreen anyway, etc. ckcmai.c, ckuusx.c, 1 Mar 99.
- Added -DDCLGETCWD to CFLAGS for is5r3jc. makefile, 1 Mar 99.
- Fixed arrangement of horizontal lines around file transfer and around
- CONNECT-mode help text. ckucns.c, ck[duv]con.c, 1 Mar 99.
- Updated SHOW FEATURES list to say "No making connections" if NOLOCAL defined,
- and fixed some typos. ckuus5.c, 1 Mar 99.
- Fixed an unguarded reference to tcharset in ckcfns.c, 1 Mar 99.
- Updated help text for RECEIVE and GET, plus help text for new K95 Kverbs from
- Jeff. ckuus2.c, 1 Mar 99.
- "send blah", where blah is a file that lacks read permission, did not produce
- an error message. Fixed in ckuusr.c, 1 Mar 99.
- Changed {SEND,RECEIVE,GET} {/MOVE-TO:,/RENAME-TO:} to save and restore global
- values snd_move, snd_rename, rcv_move, rcv_rename values. ckuus[r56x].c,
- 1 Mar 99.
- Added global {SEND,RECEIVE} {/MOVE-TO:,/RENAME-TO:} values to SHOW FILE,
- and finally added askmore() to SHOW FILE, yuk. ckuus4.c, 1 Mar 99.
- Added SET { SEND, RECEIVE } { MOVE-TO:, RENAME-TO: } to set global values
- for these. ckuus[27].c, 1 Mar 99.
- Changes to SHOW DIAL for TAPI and SET WIN95 OVERLAPPED-IO from Jeff.
- ckuus[47].c, 1 Mar 99.
- Updated HP-UX 10.30 and 11.00 targets from John Bigg of HP: makefile, 2 Mar 99.
- Yesterday's change broke the SET TRANSFER DISPLAY command. Fixed in ckcmai.c,
- ckuus[7x].c, ckcker.h, 2 Mar 99.
- Fixed SET TRANSFER DISPLAY SERIAL to wrap dots based on actual terminal width
- rather than assuming 80. ckuusx.c, 2 Mar 99.
- SEND /NOBACKUP was broken by a missing comment closer. ckuusr.c, 2 Mar 99.
- Ditto for GET /DELETE. ckuus6.c, 2 Mar 99.
- "type /?" bad news -- since its FDB had file first and switch second, "/?"
- tried to build a list of all files in the root directory. Rearranged to have
- switch first, file second, like all the other commands. ckuusr.c, 2 Mar 99.
- Fixed an unguarded reference to pipesend. ckcfns.c, 2 Mar 99.
- Started work on PURGE command (to remove all but a given number of backup
- files). Will finish tomorrow. ckuusr.[ch], ckuus7.c, 2 Mar 99.
- Added ^D and ^U to default prefixing table, since these act like LF when
- followed by ~ when going through an Rlogin connection. ckcmai.c, 3 Mar 99.
- Syntax corrections. ckuus[27x].c, ckvcon.c, 3 Mar 99.
- It seems that streaming transfers are sensitive to "X" interruption if it
- happens in a certain spot -- just at the beginning and/or just at the end.
- Found and fixed a spot in input() that might have been causing this (no,
- it didn't fix it). ckcfn2.c, 3 Mar 99.
- filhelp() was calling isdir() on every file. This is no longer necessary,
- since the parsing function that called it has already filtered out file and/or
- directory names by calling nzxpand() with the appropriate flags. Commented
- out this call to isdir(). ckucmd.c, 3 Mar 99.
- SEND /RECURSIVE ./?<Ctrl-U> left recursive flag stuck on. Moved the resetting
- of recursive and matchdot to the top of the reparse loop, rather than the top
- of the parse loop. ckuus5.c, 3 Mar 99.
- Sending to IKSD, logged in as anonymous, was failing with "directory creation
- failure" even when sending a regular file not containing any directory parts
- in its name. The problem was in zmkdir(), but I can't imagine why we weren't
- seeing the same failures before (and we weren't -- lots of people were
- uploading stuff to incoming thru IKSD). zmkdir() is always called when
- receiving a file to see if the file contains any directory parts, and if so,
- to try to create them. zmkdir() unconditionally failed if called by guest.
- Fixed it to fail only when called by guest AND it would have had to create a
- directory. ckufio.c, 3 Mar 99.
- Meanwhile, zmkdir() actually *would* create directories even when in server
- mode and MKDIR was DISABLEd, oops. Fixed in zmkdir(), ckufio.c, 3 Mar 99.
- An SSH-related update to ckcnet.c from Jeff. 3 Mar 99.
- Discovered that dialing out from VMS (yes, I can finally do it!) tends not
- to work at all. Why? VMS does not support RTS/CTS but the modem's factory
- default is to use RTS/CTS. The modem init string might have 30-40 characters
- in it, or more (e.g. USR). VMS gets data overruns on its serial port when
- reading back the echo and then loses the OK, because it has not yet sent the
- command to the modem that tells it to use local Xon/Xoff flow control. SET
- DIAL PACING 150 does the trick. Changed the startup value for DIAL PACING to
- be 150 if CK_RTSCTS is not defined, and changed the initial DIAL FLOW value
- to be XON/XOFF for VMS, rather than AUTO (although AUTO actually did result
- in Xon/Xoff, but why bother). ckudia.c, 5 Mar 99.
- Made default flow control in VMS for all types of connections it supports be
- "Xon/Xoff" (which really translates to TTSYNC/HOSTSYNC, which means "use an
- appropriate method of flow control instead of dropping incoming bytes on the
- floor for no reason"). ckcmai.c, 5 Mar 99.
- With these changes, VMS dialouts work -- a little rocky on the initial init
- string, but once the flow control is set on both ends, the connection is fine;
- downloads go fast, but uploads are faster. There are no hiccups or glitches,
- even at 38400 or 57600 bps on the Alpha PWS 433/au.
- Fixed some silly dialing messages, like "Will redial in 1 second, press any
- key to redial immediately...". ckuus6.c, 5 Mar 99.
- Fixed "red" to be an acceptable synonym for REDIAL on VMS. ckuusr.c, 5 Mar 99.
- Discovered all kinds of problems dialing without flow control -- SET DIAL
- PACING was not being obeyed in many places. Fixed in ckudia.c, 6 Mar 99.
- When dialing out from VMS and then being hung up on by the remote, VMS system
- services would thenceforth refuse to return the modem signals, and so ttchk()
- returned 0 or -1 (indicating ttgmdm() failure) rather than -2 to indicate the
- connection was lost, and therefore EXIT would give the message "A serial
- connection might be active... OK to exit?". Fixed by keeping Yet Another
- Global Status Variable. ckvtio.c, 6 Mar 99.
- The long modem setup sequence was unnecessary and annoying when redialing,
- so now we jump around on the 2nd and subsequent attempts. ckudia.c, 6 Mar 99.
- Got rid of the separate ATT or ATP command when the user had not given a SET
- MODEM COMMAND { PULSE, DIAL } or a SET MODEL DIAL-COMMAND command, making the
- dial command be ATDT or ATDP instead. ckudia.c, 6 Mar 99.
- Enabled connection log in VMS. ckvfio.c, 6 Mar 99.
- VMS was still complaining "terminal type not supported" when given a SET
- TRANSFER DISPLAY FULL command. Fixed in doxdis(): ckuus7.c, 6 Mar 99.
- Filename shown in VMS file transfer display is much too long. Changed
- screen() to call zrelname() on it. ckuusx.c, 6 Mar 99.
- The sequence DISABLE DELETE, SET FILE COLLISION UPDATE would fail because of
- a misplaced security check. The check was moved into the protocol module
- where it belongs. ckuus7.c, ckcpro.w, 6 Mar 99.
- Removed about 560 lines of #ifdef OLDTBCODE..#endif junk from ckudia.c. If
- anybody ever wants it back they can get it from version 6.0. 6 Mar 99.
- The big problem with dialing without hardware flow control is that the first
- thing we send to the modem is a big long init string, like:
- ATQ0E1V1X4&A3&S0&C1&D2&N0&Y3S14=0
- The modem can take it, but the computer might not be able to absorb the echo
- (or worse, the response), especially at high speeds. So it's essential to set
- up the flow control first, before sending any long strings to the modem. But
- this requires that the modem is first set up to produce result codes. So --
- for AT-command-set modems only -- we now send ATQ0<CR> first, up to four
- times, looking for an "OK" or "0" response, and taking various (increasingly
- drastic measures) if it doesn't come (send BREAK, hangup, etc), and then we
- set the modem's flow control, and THEN we send the init string and the rest.
- This works way better. ckudia.c, 6 Mar 99.
- Added SET HINTS { ON, OFF }. ckuusr.[ch], ckuus3.c, 6 Mar 99.
- Since control-char unprefixing is now the default, this is likely to cause
- trouble to some people. If sending a file fails and PREFIXING is not ALL,
- and the transfer was not deliberately interrupted, we now print a hint (if
- HINTS are ON) to try it again with SET PREFIXING ALL (or PARITY SPACE, or
- ROBUST, ...) -- our first hint. Made a similar set of hints for failure to
- RECEIVE or GET files. And a few others. ckuus[r345].c, 6 Mar 99.
- SET PREFIXING ALL sets prefixing to PX_ALL; now so does SET CONTROL PREFIX ALL.
- ckuus3.c, 6 Mar 99.
- -- add hints for dial failure.
- Corrections from Michal Jaegermann <michal@ellpspace.math.ualberta.ca>:
- . One of the sprintf's in nxtdir() did not have enough %s's: ckuus4.c.
- . An sprintf in v(nday) referenced a long with %d: ckuus4.c.
- . Missing parens around 4th xxscreen() arg supplied in ckuusx.c & ckcfn2.c.
- . Superfluous pointer dereference (*p++;) in arraynam: ckuus5.c.
- . ckxlogin/out() prototypes moved from ckuusr.h to ckcdeb.h.
- . ckxlogin() called with one too few args: ckcpro.w.
- . Various static declarations of unused or nonexistent variables or functions.
- Also, he objected to Kermit sending the user ID ahead on TELNET connections --
- "There is not a shred of guarantee that a login on remote will be the same as
- a local one" -- and suggested the default be not to send it. This will
- obviously be controversial, but I tend to agree, erring on the side of safety
- and predictability (for scripts). For now I just made a symbol NOSENDUID that
- can be added to CFLAGS to reverse the default at compile time. A more
- intelligent default might be to send the ID if we're on the same "network"
- (whatever that is), and not send it otherwise. Or maybe not. ckcdeb.h,
- ckctel.c, 7 Mar 99.
- Tightened up dialing procedures some more -- e.g. combined the speaker and
- volume commands. Found that my abbreviated redialing code from yesterday had
- (more than) a few problems. The most important lesson is that it's not
- sufficient to just keep sending the ATDTnnnnn command. First we have make
- sure the modem is still sentient; thus the "send ATQ0" loop must be executed
- before each redial as well as before the original call. ckudia.c, 7 Mar 99.
- My understanding of the VMS terminal driver is that if the device has the
- TT$M_MODEM characteristic, then:
- 1. When the application opens the device, VMS turns on DTR.
- 2. The CD signal is ignored until it comes up; after that, loss of
- CD causes the SS$_HANGUP error.
- After 6 hours of experimentation with dialing and redialing on VMS, I made two
- discoveries: (1) attempts to read from a /MODEM device during dialing
- (i.e. before CD has ever been turned on) often result in SS$_HANGUP, and so
- this error must be ignored during dialing; and (2) VMS periodically blinks DTR
- and RTS on the device while it is not presenting the CD signal; Kermit is not
- doing this, VMS is doing it. This can be observed simply by telling Kermit
- to "set line tta0" and then watching the modem lights for a few minutes.
- This of course causes any normal modem to immediately abandon a call in
- progress. The remote answers the phone, we hear the negotiation tones going
- and then suddenly "click" and NO CARRIER. ATI6 (to a USR Courier) says
- "Disconnect reason: DTR dropped". The modem lights confirm -- VMS turns off
- DTR (and RTS) for 5 seconds right in the middle of the modem-to-modem
- negotiations. The only reason dialing out ever works at all is that DTR stays
- up for 30 seconds at time. If a call is placed at just the right instant and
- is answered within 30 seconds, VMS leaves DTR on thereafter.
- Of course we can give the modem the DTR override command (AT&D0), but this
- eliminates the possibility of hanging up the call by dropping DTR, and in fact
- would leave open a rather gaping security hole.
- A workaround was eventually identified: Tell the modem to make DSR track CD.
- Explanation: when a port is opened, as soon as VMS sees DSR with no CD, it
- starts the 30-second-on/5-second-off DTR/RTS blinking cycle. Therefore if the
- modem does not turn DSR on, and VMS won't blink. This is less than satisfying,
- though, because it is exactly opposite of (say) SunOS, where you can't dial
- out unless DSR is ON. There should be a way to tell VMS to leave DTR up solid
- when making a dialout call. Init strings of all AT-command-set modems changed
- to include "&S1" within #ifdef VMS..#endif. This is no help at all for modems
- that are do not use the AT command set. ckudia.c, 7 Mar 99.
- David Sanderson <dws@sgi.net> noticed that window-size-change interrupts
- weren't working any more; cause: <signal.h> was left out of the ckcnet/ckctel
- split. Fixed in ckctel.c, 7 Mar 99.
- From Jeff, 8 Mar 99:
- . ckutio.c - ttinc() returning -3 is a special return value that
- indicates that the "Session Limit" has expired. SET SESSION-LIMIT. I
- do not think that this has been implemented in Unix or VMS yet. I
- have changed all references to -3 in ttinc() to -4.
- . ckuath.c - lots of rlogin stuff.
- . ckcdeb.h - Some NT Kerberos defines and the new NOSENDUID cannot be
- defined if CK_AUTHENTICATION is defined since the UID is required for
- successful completion.
- . ckcnet.c - k5 rlogin and some other little things.
- Fixed SHOW COMM for VMS to show the actual speed rather than "unknown" and
- also not to write "(closed)" after the device name. The source of confusion
- was that CK_TTYFD is defined for VMS, but instead of referencing the ttyfd
- variable (which is always -1 in VMS) we have to call the vmsttyfd() function.
- ckuus4.c, 8 Mar 99.
- Verified that it is indeed IMpossible to get the current speed of a serial
- device in VMS. The IO$_SENSEMODE() call returns the permanent speed, not the
- current, actual one. Added notes to the code about this so I don't waste
- another half-day on this one. ckvtio.c, 8 Mar 99.
- Added -DNOREDIRECT to all SCO targets prior to 3.2v4.0. makefile, 8 Mar 99.
- Made transaction log unbuffered. ckufio.c, 8 Mar 99.
- Fixed zvpass() in UNIX not to accept guest logins with empty passwords.
- ckufio.c, 8 Mar 99.
- More Kerberos changes from Jeff: ckcdeb.h ckuath.c ckuus3.c ckutio.c ckcnet.c,
- 8 Mar 99.
- Fix from Jeff for IKSD negotiation problem, in which client could send
- RESP_STOP in response to REQ_START even when autodownload was ON. ckctel.c,
- 8 Mar 99.
- Made switch completion print "=" rather than ":" as the separator in VMS, for
- switches that take args. ckucmd.c, 8 Mar 99.
- Changes from Jeff to ckcnet, ckutio, and ckuath.c, mainly for Kerberos 5,
- 9 Mar 99.
- Fixed hint for failed RLOGIN commands -- it was in the wrong place.
- ckuus[r7].c, 9 Mar 99.
- Changed VMS zfcdat() to return the file's creation date, not modification
- date, to match VMS customs and usage, not to mention the fact that VMS
- C-Kermit, when receiving a file, sets the *creation* date (not modification
- date) from the A packet. Suggested by Lucas Hart. 9 Mar 99.
- Straightened up a mess regarding -DNOREDIRECT (it was not checked in enough
- places) and also made sure that NETCMD could not be defined if NOREDIRECT
- was defined. ckcdeb.h, 9 Mar 99.
- Fixed badly confused #ifdefs around "ping" and "pipe" commands. ckuusr.c,
- 9 Mar 99.
- More Kerberos-related changes from Jeff to ckcnet, ckutio, etc, plus
- ckuus[45].c, 9 Mar 99.
- Cleaned up the logic of UNIX zgetfs() a bit with respect to symlinks.
- Now "dir /dir" lists symlinks to directories, and "dir /files" lists symlinks
- to files. This was (I hope) the last remaining problem with the DIRECTORY