#! /bin/sh # patch script for converting a5 to a008 TOP=. Patch() { echo "Patch $1:"; patch -s $TOP/$1 } NewFile() { echo "New file $1"; cat >$TOP/$1 } NewDir() { echo "New directory $1"; mkdir $TOP/$1 } RmFile() { echo "Remove $1"; rm -f $TOP/$1.orig; mv $TOP/$1 $TOP/$1.orig } Patch BLURB<<'EOF-EOF-EOF' 348,349c348,349 < FlexFAX Mailing List < -------------------- --- > FlexFAX Mail List > ----------------- 354c354,358 < flexfax-request@sgi.com --- > majordomo@whizzer.wpd.sgi.com > > For example, to subscribe, send the line "subscribe flexfax" in > the body of your message. The line "help" will return a list of > the commands understood by the mailing list management software. EOF-EOF-EOF Patch HOWTO<<'EOF-EOF-EOF' 1c1 < $Header: /usr/people/sam/fax/RCS/HOWTO,v 1.13 93/04/18 18:06:45 sam Exp $ --- > $Header: /usr/people/sam/fax/RCS/HOWTO,v 1.14 93/05/24 11:42:16 sam Exp $ 105c105,109 < flexfax-request@sgi.com --- > majordomo@whizzer.wpd.sgi.com > > For example, to subscribe, send the line "subscribe flexfax" in > the body of your message. The line "help" will return a list of > the commands understood by the mailing list management software. EOF-EOF-EOF Patch README<<'EOF-EOF-EOF' 1c1 < $Header: /usr/people/sam/fax/RCS/README,v 1.48 93/05/17 16:13:01 sam Exp $ --- > $Header: /usr/people/sam/fax/RCS/README,v 1.50 93/06/25 14:56:34 sam Exp $ 69a70 > USR Sportster (firmware revision XXX or newer) 86c87 < Abaton InterFax 24/96 --- > Abaton InterFax 24/96 NOTE: THE ABATON DRIVER IS CURRENTLY BUSTED 306,307c307,308 < Directory for library files /usr/local/lib/fax < Directory for sendfax filters: /usr/local/lib/fax --- > Directory for lib data files /usr/local/lib/fax > Directory for lib executables: /usr/local/lib/fax 466,467c467,468 < software flow control (and all the Class 1 modems tried so far do < not support hardware flow control) --- > software flow control (and most of the Class 1 modems tried so far > do not support hardware flow control) 480c481,482 < (something that does not work well with many fax modems). --- > (something that does not work well with many fax modems)--most folks > use /dev/cu* for communicating with modems. 612c614,616 < placing a call--e.g AT+FCLASS=0DT. --- > placing a call--e.g AT+FCLASS=0DT. Alternatively, you > can fiddle with the configuration parameters and keep the modem setup > for data use when the server is not actively using the modem. 682,698c686,705 < Incoming facsimile are placed in the recvq subdirectory of the < spooling area and probably will need to be cleaned up periodically. < Likewise there is logging information in the log subdirectory and < accounting information in the etc subdirectory of the spooling area < that may need some attention (scripts similar to those used for < maintaining sendmail and uucp logs and queues should probably be run < out of cron). If you want to do accounting check out the simple-minded < awk scripts util/xfer.awk util/xferdest.awk for a basic attack on how < to process the etc/xferlog accounting file maintained for facsimile < transmissions and receptions. Otherwise the only matter to be < concerned with is the support for data connections. If your modems are < capable of differentiating data connections from facsimile connections < the fax server can invoke a getty process and permit incoming data < connections. Beware that if you enable this facility you should take the < normal precautions you would take when there are dialup ports on your < machine. Specifically, make sure that you have passwords, appropriate < file protections, and proper configuration of uucp or similar. --- > Incoming facsimile are placed in the recvq subdirectory of the spooling > area and probably will need to be cleaned up periodically. Likewise > there is logging information in the log subdirectory and accounting > information in the etc subdirectory of the spooling area that may need > some attention (scripts similar to those used for maintaining sendmail > and uucp logs and queues should probably be run out of cron). If you > want to do accounting check out the simple-minded awk scripts > util/xfer.awk util/xferdest.awk for a basic attack on how to process > the etc/xferlog accounting file maintained for facsimile transmissions > and receptions. Otherwise the only matter to be concerned with is the > support for data connections. If your modems are capable of > differentiating data connections from facsimile connections the fax > server can invoke a getty process and permit incoming data > connections. Alternatively, if your modem does not support an adaptive > answer facility, but it is a Class 1 modem, the server may be able to > do adaptive answering in software. In any event, beware that if you > enable data connections you should take the normal precautions you > would take when there are dialup ports on your machine. Specifically, > make sure that you have passwords, appropriate file protections, and > proper configuration of uucp or similar. 699a707,718 > If you encounter problems with sending or receiving facsimile you can > enable copious tracing information by editing the configuration > file(s). Consult the section on Troubleshooting and the config(4F) and > log(4F) manual pages. > > > Adaptive-answering Strategies > ----------------------------- > If your modem supports a good adaptive answering facility, then it > should be enabled with the ModemSetupAACmd and the server system will > automatically service fax or data calls as appropriate. > 702,708c721,725 < facsimile is supported without problems. If you want to always process < incoming calls fax connections, then you do not need to do anything; < this is the normal setup. If you want to always process incoming calls < as data connections, then you should setup your modem configuration so < that the ModemAnswerCmd parameter in the configuration file causes the < phone to be answered strictly as a data modem. For example, if you < have a Class 2 modem, the following should do this: --- > facsimile is supported without problems. If you have a Class 1 modem, > then you can request that the server employ a simple adaptive answering > strategy whereby incoming calls are first answered as if they are for a > fax machine and, if that fails, then answered as if they are for a data > modem. This facility is enabled by specifying something like: 710c727,730 < ModemAnswerCmd: +FCLASS=0A --- > AdaptiveAnswer: yes # enable adaptive answer > ModemAnswerCmd: +FCLASS=1;A # default is to answer as fax > ModemAnswerDataCmd: H+FCLASS=0;A # hangup and answer as data > Class1RecvIdentTimer: 10000 # timeout fax answer in 10 secs 711a732,784 > in the configuration file. The above lines cause the fax server to do > the following in response to an incoming phone call: > > 1. Issue "AT+FCLASS=1;A" to answer the phone call in Class 1; > i.e. as a fax machine (issuing CNG tones). > 2. Send TSI and DIS frames as required by the fax protocol. > 3. Wait for DCS from the caller (if it is a fax machine). > 4. Timeout waiting for DCS in 10 seconds (or whatever is specified > for Class1RecvIdentTimer). > 5. Issue "ATH+FCLASS=0;A" to hangup and then re-answer the phone > in Class 0; i.e. as a data modem. > > This technique assumes many things about the capabilities of the modem > and the local telephony service and may not work for all Class 1 modems > or for all locales. > > A second facility supported by the fax server in lieu of adaptive > answering is a ``rotary of answering techniques''. The general idea is > that a list of alternative ways to answer the phone is supplied and the > server will rotate through the list until it finds one that works. For > example, one might specify something like: > > AnswerRotary: "fax data" > > which would instruct the server to answer incoming calls as if they > were from a fax machine until a call was received from something other > than a fax machine, in which case it would then answer subsequent calls > as a data modem until a non-data call was received (in which case it > would go back to fax). The rotary list can have up to three items, > with items being selected from one of: fax, data, voice, and any > (answer a call of an unknown type). The voice answering request is > reserved for future development. Finally, in conjunction with the > rotary answer facility there is an AnswerBias parameter that can be > used to specify an index into the rotary list to use after > *successfull* calls. In the above example, this parameter can be used, > to force calls to always be answered first as data by specifying: > > AnswerRotary: "fax data" > AnswerBias: 1 > > > Non-adaptive-answering Strategies > --------------------------------- > If you want to always process incoming calls as fax connections, then > you do not need to do anything; this is the normal setup. If you want > to always process incoming calls as data connections, then you should > setup your modem configuration so that the ModemAnswerCmd parameter in > the configuration file causes the phone to be answered strictly as a > data modem. For example, if you have a Class 1 or Class 2 modem, the > following should do this: > > ModemAnswerCmd: +FCLASS=0;A > 720,725c793,796 < server pick up the phone. Note that with a little judicious config < file hacking, you can arrange to have the server answer the phone < either as a data modem or as a fax modem. Future versions of the < system will provide better support for this (i.e. not require that you < edit the configuration file before telling the server to answer the < phone). --- > server pick up the phone. Note that by using the -h option to faxanswer > you can control whether the fax server answers a phone call as fax, > or data (answering as voice is also supported for compatibility with > future work). 727,730d797 < If you encounter problems with sending or receiving facsimile you can < enable copious tracing information by editing the configuration < file(s). Consult the next section and the config(4F) and log(4F) < manual pages. 732d798 < 799,803c865,869 < Andrew Ford Wolfgang Henke Bert Hooyman Masao Kitano < Carsten Koch Rickard Linck Kevin McManamon Bill Morrow < Jonas Olsson Dave Packer Damon Permezel David Pike < Amir Plivatsky Andy Rabagliati Eric Rescorla Daniel Rosenblatt < Tim Rylance Brent Townshend --- > Andrew Ford Wolfgang Henke Bert Hooyman Brian Katzung > Masao Kitano Carsten Koch Rickard Linck Kevin McManamon > Bill Morrow Jonas Olsson Dave Packer Damon Permezel > David Pike Amir Plivatsky Andy Rabagliati Eric Rescorla > Daniel Rosenblatt Tim Rylance Brent Townshend 821c887 < such as getting your name removed from it, send a request to --- > such as getting your name removed from it, send your request to 823c889 < flexfax-request@sgi.com --- > majordomo@whizzer.wpd.sgi.com 825,828c891,893 < If you are a first-time user of this software you can join the mailing < list by filling out the survey form in the file SURVEY and post it to < the above email address (the form is setup as an MH form file to < simplify this procedure). --- > For example, to subscribe, send the line "subscribe flexfax" in > the body of your message. The line "help" will return a list of > the commands understood by the mailing list management software. 829a895,898 > If you have not previously done so, please fill out the survey form in > the file SURVEY and post it to flexfax-survey@whizzer.wpd.sgi.com (the > form is setup as an MH form file to simplify this procedure). > 874,876d942 < < $Header: /usr/people/sam/fax/RCS/README,v 1.48 93/05/17 16:13:01 sam Exp $ < 896a963,965 > The file 3.2.patch in the above ftp directories is a shell > script that should be applied to the 3.2beta source code. > 899a969,988 > > TIFF Mailing List > ----------------- > A mailing list for users of this software is located on sgi.com. > If you want to join this mailing list or have a list-related request > such as getting your name removed from it, send a request to > > majordomo@whizzer.wpd.sgi.com > > For example, to subscribe, send the line "subscribe tiff" in > the body of your message. The line "help" will return a list of > the commands understood by the mailing list management software. > > Submissions (including bug reports) should be directed to: > > tiff@sgi.com > > When corresponding about this software please always specify what > version you have, what system you're running on. > EOF-EOF-EOF Patch SURVEY<<'EOF-EOF-EOF' 1c1 < To: flexfax-request@sgi.com (FlexFAX Mailing List Administrator) --- > To: flexfax-survey@whizzer.wpd.sgi.com (FlexFAX Survey-or) EOF-EOF-EOF Patch configure<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/RCS/configure,v 1.68 93/05/17 15:37:55 sam Exp $ --- > # $Header: /usr/people/sam/fax/RCS/configure,v 1.69 93/06/18 11:43:28 sam Exp $ 582,583c582,583 < getParameter LIB $1; FAX_LIBDIR="$param" < FAX_FILTERDIR="$param" --- > getParameter LIBDATA $1; FAX_LIBDATA="$param" > getParameter LIBEXEC $1; FAX_LIBEXEC="$param" 603,604c603,605 < protoFAX_LIBDIR="$FAX_LIBDIR" < protoFAX_FILTERDIR="$FAX_FILTERDIR" --- > protoFAX_LIBDATA="$FAX_LIBDATA" > protoFAX_LIBEXEC="$FAX_LIBEXEC" > protoFAX_LIBFILTER="$FAX_LIBFILTER" 627,628c628,629 < Directory for library files $FAX_LIBDIR < Directory for sendfax filters: $FAX_FILTERDIR --- > Directory for lib data files: $FAX_LIBDATA > Directory for lib executables: $FAX_LIBEXEC 696,700c697,700 < promptForNonNullStringParameter "$FAX_LIBDIR" \ < "Directory to install library files"; FAX_LIBDIR="$param" < promptForNonNullStringParameter "$FAX_FILTERDIR" \ < "Directory to install sendfax filter programs"; < FAX_FILTERDIR="$param" --- > promptForNonNullStringParameter "$FAX_LIBDATA" \ > "Directory to install library data files"; FAX_LIBDATA="$param" > promptForNonNullStringParameter "$FAX_LIBEXEC" \ > "Directory to install library executables"; FAX_LIBEXEC="$param" 756c756,757 < -o "$FAX_LIBDIR" != "$protoFAX_LIBDIR" \ --- > -o "$FAX_LIBDATA" != "$protoFAX_LIBDATA" \ > -o "$FAX_LIBEXEC" != "$protoFAX_LIBEXEC" \ 772c773,774 < "/^LIB[ ]*=/s;=[^#]*;=${FAX_LIBDIR};" \ --- > "/^LIBDATA[ ]*=/s;=[^#]*;=${FAX_LIBDATA};" \ > "/^LIBEXEC[ ]*=/s;=[^#]*;=${FAX_LIBEXEC};" \ 794d795 < getHParameter FAX_LIBDIR $f; protoFAX_LIBDIR="$param" 796c797,798 < getHParameter FAX_FILTERDIR $f; protoFAX_FILTERDIR="$param" --- > getHParameter FAX_LIBDATA $f; protoFAX_LIBDATA="$param" > getHParameter FAX_LIBEXEC $f; protoFAX_LIBEXEC="$param" 799c801,802 < if [ "$FAX_LIBDIR" != "$protoFAX_LIBDIR" \ --- > if [ "$FAX_LIBDATA" != "$protoFAX_LIBDATA" \ > -o "$FAX_LIBEXEC" != "$protoFAX_LIBEXEC" \ 801d803 < -o "$FAX_FILTERDIR" != "$protoFAX_FILTERDIR" \ 809c811,812 < "/FAX_LIBDIR/s;${protoFAX_LIBDIR};${FAX_LIBDIR};" \ --- > "/FAX_LIBDATA/s;${protoFAX_LIBDATA};${FAX_LIBDATA};" \ > "/FAX_LIBEXEC/s;${protoFAX_LIBEXEC};${FAX_LIBEXEC};" \ EOF-EOF-EOF Patch distrules<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/RCS/distrules,v 1.55 93/05/20 15:53:43 sam Exp $ --- > # $Header: /usr/people/sam/fax/RCS/distrules,v 1.57 93/06/24 13:48:13 sam Exp $ 200a201 > etc/probemodem.sh \ 306d306 < faxd/FaxRecvdData.c++ \ 309d308 < faxd/FaxRequestData.c++ \ EOF-EOF-EOF Patch dist/flexfax.alpha<<'EOF-EOF-EOF' 1c1 < define ALPHA 5 --- > define ALPHA 008 EOF-EOF-EOF Patch dist/newalpha<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/dist/RCS/newalpha,v 1.2 93/04/18 18:05:01 sam Exp $ --- > # $Header: /usr/people/sam/fax/dist/RCS/newalpha,v 1.3 93/05/21 12:13:46 sam Exp $ 29,30c29,30 < ALPHA=`cat flexfax.alpha|sed -e 's/define.ALPHA.//'` < ALPHA=`expr $ALPHA + 1` --- > ALPHA=`cat flexfax.alpha`; rm -f flexfax.alpha > echo "$ALPHA" | awk '{ printf "define ALPHA %03d\n", $3+1}' > flexfax.alpha 32c32 < ALPHA=1 --- > echo "define ALPHA 001" >flexfax.alpha 34,35d33 < rm -f flexfax.alpha < echo "define ALPHA ${ALPHA}" >flexfax.alpha EOF-EOF-EOF Patch etc/config.att-dataport<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.att-dataport,v 1.2 93/05/17 16:27:09 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.att-dataport,v 1.3 93/05/26 11:16:05 sam Exp $ 7a8,9 > # > # CONFIG: CLASS1: 144: Manufacturer='AT&T' Model=Dataport EOF-EOF-EOF Patch etc/config.dsi-scout+<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.dsi-scout+,v 1.9 93/05/06 12:51:11 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.dsi-scout+,v 1.10 93/05/26 11:16:50 sam Exp $ 8a9,10 > # > # CONFIG: CLASS1: 961: Manufacturer=Digicom Model=Scout+ EOF-EOF-EOF Patch etc/config.everex-2496d<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.everex-2496d,v 1.10 93/05/06 12:51:11 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.everex-2496d,v 1.11 93/05/26 11:16:51 sam Exp $ 7a8,9 > # > # CONFIG: CLASS2: Everex* EOF-EOF-EOF Patch etc/config.mt-1432<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.mt-1432,v 1.3 93/05/06 12:51:12 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.mt-1432,v 1.4 93/05/26 11:16:51 sam Exp $ 3a4,5 > # > # CONFIG: CLASS2: Multi-Tech* EOF-EOF-EOF Patch etc/config.nuvo-voyager<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.nuvo-voyager,v 1.5 93/05/06 12:51:13 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.nuvo-voyager,v 1.6 93/05/26 11:16:52 sam Exp $ 6a7,8 > # > # CONFIG: CLASS1: 242: Manufacturer=Nuvo Model="Voyager 9642PFX" EOF-EOF-EOF Patch etc/config.rockwell<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.rockwell,v 1.12 93/05/06 12:51:13 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.rockwell,v 1.13 93/05/26 11:16:53 sam Exp $ 16a17,18 > # > # CONFIG: CLASS2: ROCKWELL* EOF-EOF-EOF Patch etc/config.rockwell-class1<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.rockwell-class1,v 1.13 93/05/06 12:51:14 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.rockwell-class1,v 1.14 93/05/26 11:16:54 sam Exp $ 9a10,12 > # > # CONFIG: CLASS1: 999: Manufacturer=ROCKWELL Model=RC144AC > # CONFIG: CLASS1: 998: Manufacturer=ROCKWELL Model=RC96AC EOF-EOF-EOF Patch etc/config.telebit-wb<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.telebit-wb,v 1.4 93/05/06 12:51:15 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.telebit-wb,v 1.5 93/05/26 11:16:55 sam Exp $ 5a6,7 > # > # CONFIG: CLASS2: Telebit* EOF-EOF-EOF Patch etc/config.usr-courier<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.usr-courier,v 1.4 93/05/11 14:23:10 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.usr-courier,v 1.5 93/05/26 11:16:56 sam Exp $ 7a8,9 > # > # CONFIG: CLASS1: 1444: Manufacturer=USRobotics Model=Courier EOF-EOF-EOF Patch etc/config.zyxel-1496e<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/etc/RCS/config.zyxel-1496e,v 1.12 93/05/11 16:50:13 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/config.zyxel-1496e,v 1.13 93/05/26 11:16:57 sam Exp $ 12a13,14 > # > # CONFIG: CLASS2: ZyXEL* EOF-EOF-EOF Patch etc/faxaddmodem.sh<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/etc/RCS/faxaddmodem.sh,v 1.53 93/05/11 14:20:42 sam Exp $ --- > # $Header: /usr/people/sam/fax/etc/RCS/faxaddmodem.sh,v 1.55 93/06/23 14:04:05 sam Exp $ 92a93 > MODEMCONFIG=$SPOOL/etc # location of modem configuration files 397c398 < x=`ypcat services 2>/dev/null | grep '^fax'` --- > x=`ypcat services 2>/dev/null | grep '^fax[ ]'` 399c400 < x=`grep '^fax' $SERVICES` --- > x=`grep '^fax[ ]' $SERVICES` 929c930 < ModemType="" Manufacturer="" Model="" --- > ModemType="" Manufacturer="" Model="" ProtoType="config.skel" 936c937 < ModemType="Class2" --- > ModemType=Class2 938c939,947 < --- > # > # Use AT+FMDL? to get the model and AT+FMFR? to get > # manuafacturer's identity and then compare them against > # the set of known values in the Class 2 config files. > # Note that we do this with a tricky bit of shell > # hacking--generating a case statement that we > # then eval with the result being the setup of the > # ProtoType shell variable. > # 945a955,962 > > eval `(cd $MODEMCONFIG; \ > grep 'CONFIG:[ ]*CLASS2' config.* |\ > awk -F: ' > BEGIN { print "case \"$Manufacturer-$Model\" in" } > { print $4 ") ProtoType=" $1 ";;" } > END { print "*) ProtoType=config.class2;;"; print "esac" } > ')` 948,949c965 < ModemType="Class1"; < Manufacturer=Unknown Model=Unknown --- > ModemType=Class1 Manufacturer=Unknown Model=Unknown 952,953c968,973 < # Use ATI0 to get the product code--are these < # really going to be unique? --- > # Use ATI0 to get the product code and then compare > # it against the set of known values in the config > # files. Note that we do this with a tricky bit of > # shell hacking--generating a case statement that we > # then eval with the result being the setup of the > # Manufacturer, Model, and ProtoType shell variables. 956,961c976,984 < case "$RESPONSE" in < 144) Manufacturer=ATT Model=DataPort;; < 242) Manufacturer=Nuvo Model="Voyager 9642PFX";; < 961) Manufacturer=Digicom Model=Scout+;; < 1444) Manufacturer=USRobotics Model=Courier;; < esac --- > echo "Product code is \"$RESPONSE\"." > > eval `(cd $MODEMCONFIG; \ > grep 'CONFIG:[ ]*CLASS1' config.* |\ > awk -F: ' > BEGIN { print "case \"$RESPONSE\" in" } > { print $4 ") " $5 " ProtoType=" $1 ";;" } > END { print "*) ProtoType=config.class1;;"; print "esac" } > ')` 968c991 < giveup; --- > giveup 1001d1023 < ProtoType="config.skel" 1003,1029c1025,1026 < Class2) < case $Manufacturer in < ZyXEL*) < echo "Using prototype ZyXEL configuration file..." < ProtoType=config.zyxel-1496e < ;; < ROCKWELL*) < echo "Using prototype Rockwell configuration file..." < ProtoType=config.rockwell < ;; < Everex*) < echo "Using prototype Everex 24/96D configuration file..." < ProtoType=config.everex-2496d < ;; < Telebit*) < echo "Using prototype Telebit WorldBlazer configuration file..." < ProtoType=config.telebit-wb < ;; < Multi-Tech*) < echo "Using prototype Multi-Tech $Model configuration file..." < ProtoType=config.mt-1432 < ;; < *) < echo "Using prototype Class 2 configuration file..." < ProtoType=config.class2 < ;; < esac --- > Class1|Class2) > echo "Using prototype configuration file $ProtoType..." 1031,1058d1027 < Class1) < case $Manufacturer-$Model in < ROCKWELL*) < echo "Using prototype Rockwell Class 1 configuration file..." < ProtoType=config.rockwell-class1 < ;; < Digicom*) < echo "Using prototype Digicom configuration file..." < ProtoType=config.dsi-scout+ < ;; < Nuvo*) < echo "Using prototype Nuvo configuration file..." < ProtoType=config.nuvo-voyager < ;; < ATT-DataPort) < echo "Using prototype AT&T DataPort configuration file..." < ProtoType=config.att-dataport < ;; < USRobotics-Courier) < echo "Using prototype US Robotics Courier configuration file..." < ProtoType=config.usr-courier < ;; < *) < echo "Using prototype Class 1 configuration file..." < ProtoType=config.class1 < ;; < esac < ;; 1065c1034 < proto=$SPOOL/etc/$ProtoType --- > proto=$MODEMCONFIG/$ProtoType 1080c1049 < proto=$SPOOL/etc/$ProtoType; --- > proto=$MODEMCONFIG/$ProtoType; 1594c1563 < eval sed $ServerCmds $ModemCmds $proto >$CONFIG --- > eval sed $ServerCmds $ModemCmds '-e /CONFIG:/d' $proto >$CONFIG EOF-EOF-EOF NewFile etc/probemodem.sh<<'EOF-EOF-EOF' #! /bin/sh # $Header: /usr/people/sam/fax/etc/RCS/probemodem.sh,v 1.1 93/06/24 13:45:47 sam Exp $ # # FlexFAX Facsimile Software # # Copyright (c) 1993 Sam Leffler # Copyright (c) 1993 Silicon Graphics, Inc. # # Permission to use, copy, modify, distribute, and sell this software and # its documentation for any purpose is hereby granted without fee, provided # that (i) the above copyright notices and this permission notice appear in # all copies of the software and related documentation, and (ii) the names of # Sam Leffler and Silicon Graphics may not be used in any advertising or # publicity relating to the software without the specific, prior written # permission of Sam Leffler and Silicon Graphics. # # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. # # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE # OF THIS SOFTWARE. # # # probemodem [tty] # # This script probes a modem attached to a serial line and # reports the results of certain commands. # PATH=/bin:/usr/bin:/etc test -d /usr/ucb && PATH=$PATH:/usr/ucb # Sun and others test -d /usr/bsd && PATH=$PATH:/usr/bsd # Silicon Graphics test -d /usr/5bin && PATH=/usr/5bin:$PATH:/usr/etc # Sun and others test -d /usr/sbin && PATH=/usr/sbin:$PATH # 4.4BSD-derived if [ -d /etc/saf ]; then # uname -s is unreliable on svr4 as it can return the nodename OS=svr4 else OS=`uname -s 2>/dev/null || echo unknown` # system identification fi SPEED=2400 # rate for talking to modem while [ x"$1" != x"" ] ; do case $1 in -os) OS=$2; shift;; -s) SPEED=$2; shift;; -*) echo "Usage: $0 [-os OS] [-s SPEED] [ttyname]"; exit 1;; *) TTY=$1;; esac shift done LOCKDIR=/usr/spool/locks # UUCP locking directory OUT=/tmp/addmodem$$ # temp file in which modem output is recorded CAT="cat -u" # something to do unbuffered reads and writes # # Figure out which brand of echo we have and define # prompt and printf shell functions accordingly. # Note that we assume that if the System V-style # echo is not present, then the BSD printf program # is available. # if [ `echo foo\\\c`@ = "foo@" ]; then # System V-style echo supports \r # and \c which is all that we need prompt() { echo "$* \\c" } printf() { echo "$*\\c" } elif [ "`echo -n foo`@" = "foo@" ]; then # BSD-style echo; use echo -n to get # a line without the trailing newline prompt() { echo -n "$* " } else # something else; do without prompt() { echo "$*" } fi t=`printf hello` 2>/dev/null if [ "$t" != "hello" ]; then echo "You don't seem to have a System V-style echo command" echo "or a BSD-style printf command. I'm bailing out..." exit 1 fi # # If the killall program is not present on the system # cobble together a shell function to emulate the # functionality that we need. # (killall -l >/dev/null) 2>/dev/null || { killall() { # NB: ps ax should give an error on System V, so we try it first! pid="`ps ax 2>/dev/null | grep $2 | grep -v grep | awk '{print $1;}'`" test "$pid" || pid="`ps -e | grep $2 | grep -v grep | awk '{print $2;}'`" test "$pid" && kill $1 $pid; return } } while [ -z "$TTY" -o ! -c /dev/$TTY ]; do if [ "$TTY" != "" ]; then echo "/dev/$TTY is not a terminal device." fi prompt "Serial port that modem is connected to [$TTY]?"; read TTY done # # Try to deduce if the tty devices are named in the SGI # sense (ttyd, ttym, and ttyf) or the # way that everyone else seems to do it--tty # # (I'm sure that someone will tell me there is another way as well.) # case "$OS" in IRIX) PORT=`expr $TTY : 'tty.\(.*\)'` for x in f m d; do LOCKX="$LOCKX $LOCKDIR/LCK..tty$x${PORT}" done DEVS="/dev/ttyd${PORT} /dev/ttym${PORT} /dev/ttyf${PORT}" # # NB: we use ttyd* device names in the following # work so that we are not stopped by a need for DCD. # tdev=/dev/ttyd${PORT} ;; BSDi|BSD/386|386bsd|386BSD) PORT=`expr $TTY : 'com\(.*\)'` LOCKX="$LOCKDIR/LCK..$TTY" DEVS=/dev/$TTY tdev=/dev/$TTY ;; SunOS) PORT=`expr $TTY : 'tty\(.*\)'` LOCKX="$LOCKDIR/LCK..$TTY" DEVS=/dev/$TTY tdev=/dev/$TTY ;; *) echo "Beware, I am guessing the tty naming conventions on your system:" PORT=`expr $TTY : 'tty\(.*\)'` echo "Serial port: $PORT" LOCKX="$LOCKDIR/LCK..$TTY" echo "UUCP lock file: $LOCKX" DEVS=/dev/$TTY tdev=/dev/$TTY echo "TTY device: $DEVS" ;; esac CONFIG=$CPATH.$TTY # # Check that device is not currently being used. # if [ ! -d $LOCKDIR ]; then prompt "Hmm, uucp lock files are not in \"$LOCKDIR\", where are they?" read x while [ ! -d $x ]; do prompt "Nope, \"$x\" is not a directory; try again:" read x done LOCKDIR=$x fi for x in $LOCKX; do if [ -f $x ]; then echo "Sorry, the device is currently in use by another program." exit 1 fi done # # Lock the device for later use when deducing the modem type. # JUNK="$LOCKX $OUT" trap "rm -f $JUNK; exit 1" 0 1 2 15 LOCKSTR=`expr " $$" : '.*\(..........\)'` # lock the device by all of its names for x in $LOCKX; do echo "$LOCKSTR" > $x done # zap any gettys or other users fuser -k $DEVS >/dev/null 2>&1 || { cat</dev/null 2>&1; then Stty() { stty -f $tdev $* } else Stty() { stty $* <$tdev } fi # # Send each command in SendString to the modem and collect # the result in $OUT. Read this very carefully. It's got # a lot of magic in it! # SendToModem() { Stty 0 # reset the modem (hopefully) catpid=`$CAT <$tdev >$OUT& echo $!` # start listening for output Stty $SPEED -echo -icrnl -ixon -ixoff -isig clocal; sleep 1 printf "\rATQ0V1E1\r" >$tdev; sleep 1; # enable echo and result codes for i in $*; do printf "$i\r" >$tdev; sleep 1; done kill -9 $catpid; catpid= pat=`echo "$i"|sed -e 's/[+*&$\\]/\\\\&/g'` # escape regex metacharacters RESPONSE=`tr -d '\015' < $OUT | \ sed -n "/$pat/{n;s/ *$//;p;q;}" | sed -e 's/AT\+F.*=//' -e 's/\+F.*=//'` } RESULT=""; while [ -z "$RESULT" ]; do # # This goes in the background while we try to # reset the modem. If something goes wrong, it'll # nag the user to check on the problem. # (trap 0 1 2 15; while true; do sleep 5; echo "" echo "Hmm, something seems to be hung, check your modem eh?" done)& nagpid=$! trap "rm -f $JUNK; kill $nagpid \$catpid; exit 1" 0 1 2 15 SendToModem "AT+FCLASS=?" # ask for class support kill $nagpid trap "rm -f $JUNK; test "$catpid" && kill $catpid; exit 1" 0 1 2 15 sleep 1 RESULT=`tr -d "\015" < $OUT | tail -1` if [ -z "$RESPONSE" ]; then echo "" echo "There was no response from the modem. Perhaps the modem is" echo "turned off or the cable between the modem and host is not" echo "connected. Please check the modem and hit a carriage return" prompt "when you are ready to try again:" read x fi done Try() { catpid=`$CAT <$tdev >$OUT& echo $!` # start listening for output Stty $SPEED -echo -icrnl -ixon -ixoff -isig clocal; sleep 1 for i in $*; do printf "$i\r" >$tdev; sleep 1; done kill -9 $catpid; catpid= pat=`echo "$i"|sed -e 's/[+*&$\\]/\\\\&/g'` # escape regex metacharacters RESPONSE=`tr -d '\015' < $OUT | sed -n "/$pat/{n;s/ *$//;p;q;}"` RESULT=`tr -d "\015" < $OUT | tail -1` printf "$* RESULT = \"$RESULT\" RESPONSE = \"$RESPONSE\"\n" } TryClass2Commands() { Try "AT+FCLASS=?"; Try "AT+FCLASS?" Try "AT+FCLASS=0"; Try "AT+FCLASS=1"; Try "AT+FCLASS=2" Try "AT+FCLASS?" Try "AT+FJUNK=?"; Try "AT+FJUNK?" Try "AT+FAA=?"; Try "AT+FAA?" Try "AT+FAXERR=?"; Try "AT+FAXERR?" Try "AT+FBADLIN=?"; Try "AT+FBADLIN?" Try "AT+FBADMUL=?"; Try "AT+FBADMUL?" Try "AT+FBOR=?"; Try "AT+FBOR?" Try "AT+FBUF=?"; Try "AT+FBUF?" Try "AT+FBUG=?"; Try "AT+FBUG?" Try "AT+FCIG=?"; Try "AT+FCIG?" Try "AT+FCQ=?"; Try "AT+FCQ?" Try "AT+FCR=?"; Try "AT+FCR?" Try "AT+FTBC=?"; Try "AT+FTBC?" Try "AT+FDCC=?"; Try "AT+FDCC?" Try "AT+FDCS=?"; Try "AT+FDCS?" Try "AT+FDIS=?"; Try "AT+FDIS?" Try "AT+FDT=?"; Try "AT+FDT?" Try "AT+FECM=?"; Try "AT+FECM?" Try "AT+FET=?"; Try "AT+FET?" Try "AT+FLID=?"; Try "AT+FLID?" Try "AT+FLNFC=?"; Try "AT+FLNFC?" Try "AT+FLPL=?"; Try "AT+FLPL?" Try "AT+FMDL?"; Try "AT+FMFR?" Try "AT+FMINSP=?"; Try "AT+FMINSP?" Try "AT+FPHCTO=?"; Try "AT+FPHCTO?" Try "AT+FPTS=?"; Try "AT+FPTS?" Try "AT+FRBC=?"; Try "AT+FRBC?" Try "AT+FREL=?"; Try "AT+FREL?" Try "AT+FREV?"; Try "AT+FSPL=?"; Try "AT+FSPL?" Try "AT+FTBC=?"; Try "AT+FTBC?" Try "AT+FVRFC=?"; Try "AT+FVRFC?" Try "AT+FWDFC=?"; Try "AT+FWDFC?" } TryClass1Commands() { Try "AT+FCLASS=?"; Try "AT+FCLASS?" Try "AT+FCLASS=0"; Try "AT+FCLASS=1" Try "AT+FCLASS?" Try "AT+FJUNK=?"; Try "AT+FJUNK?" Try "AT+FAA=?"; Try "AT+FAA?" Try "AT+FAE=?"; Try "AT+FAE?" Try "AT+FTH=?" Try "AT+FRH=?" Try "AT+FTM=?" Try "AT+FRM=?" Try "AT+FTS=?" Try "AT+FRS=?" } TryCommonCommands() { for i in 0 1 2 3; do Try "ATI$i" done } echo "" if [ "$RESULT" = "OK" ]; then # Looks like a Class 1 or 2 modem, get more information case "`echo $RESPONSE | sed -e 's/[()]//g'`" in 2|0,2|2,*|0,2,*) echo "This looks like a Class 2 modem." echo "" TryCommonCommands echo ""; echo "Class 2 stuff..."; echo "" TryClass2Commands ;; 0,1,2|0,1,2,*) echo "This looks like a Class 1+2 modem." echo "" TryCommonCommands echo ""; echo "Class 1 stuff..."; echo "" TryClass1Commands echo ""; echo "Class 2 stuff..."; echo "" TryClass2Commands ;; 1|0,1|0,1,*) echo "This looks like a Class 1 modem." echo "" TryCommonCommands echo ""; echo "Class 1 stuff..."; echo "" TryClass1Commands exit ;; *) echo "The result of the AT+FCLASS=? command was:" echo "" cat $OUT echo "" echo "I don't figure that it's worthwhile to continue..." exit ;; esac else echo "This not a Class 1 or Class 2 modem," exit fi EOF-EOF-EOF Patch faxcover/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/faxcover/RCS/Makefile,v 1.15 93/04/18 18:05:12 sam Exp $ --- > # $Header: /usr/people/sam/fax/faxcover/RCS/Makefile,v 1.16 93/06/18 11:44:33 sam Exp $ 49c49 < ${INSTALL} -F ${LIB} -m 644 \ --- > ${INSTALL} -F ${LIBDATA} -m 644 \ EOF-EOF-EOF Patch faxcover/faxcover.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxcover/RCS/faxcover.c++,v 1.21 93/05/17 16:59:00 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxcover/RCS/faxcover.c++,v 1.23 93/06/23 14:03:43 sam Exp $ 39a40 > #include 99a101,104 > const char* cp = getenv("FAXCOVER"); > if (cp && *cp) > cover = cp; > 189c194 < fd = ::open((char*) (fxStr(FAX_LIBDIR) | "/" | cover), O_RDONLY); --- > fd = ::open((char*) (fxStr(FAX_LIBDATA) | "/" | cover), O_RDONLY); EOF-EOF-EOF Patch faxd/Class1.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Class1.h,v 1.29 93/05/10 09:26:43 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Class1.h,v 1.31 93/06/22 18:16:18 sam Exp $ 93c93 < u_int f2, u_int dics, fxStr& emsg); --- > u_int f2, u_int dics, u_int timer, fxStr& emsg); 142c142 < fxBool sendPhaseB(TIFF* tif, Class2Params&, u_int pfm, fxStr& emsg); --- > fxBool sendPhaseB(TIFF* tif, Class2Params&, fxStr& pph, fxStr& emsg); EOF-EOF-EOF Patch faxd/Class1Poll.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Class1Poll.c++,v 1.4 93/03/25 15:13:40 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Class1Poll.c++,v 1.5 93/06/22 18:19:17 sam Exp $ 25a26 > #include "ModemConfig.h" 41c42 < return recvIdentification(FCF_CIG, cig, FCF_DTC, dtc, emsg); --- > return recvIdentification(FCF_CIG, cig, FCF_DTC, dtc, conf.t1Timer, emsg); EOF-EOF-EOF Patch faxd/Class1Recv.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Class1Recv.c++,v 1.34 93/05/10 16:28:23 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Class1Recv.c++,v 1.37 93/06/24 15:18:33 sam Exp $ 55c55 < * Process an answerresponse from the modem. --- > * Process an answer response from the modem. 59c59,60 < * message here to mean "CONNECT FAX". --- > * message here to force the high level code to > * probe further. 65c66 < { "CONNECT", 7, FaxModem::OK, FaxModem::CALLTYPE_FAX }; --- > { "CONNECT", 7, FaxModem::OK, FaxModem::CALLTYPE_UNKNOWN }; 80c81,82 < FCF_CSI|FCF_RCVR, lid, FCF_DIS|FCF_RCVR, modemDIS(), emsg); --- > FCF_CSI|FCF_RCVR, lid, FCF_DIS|FCF_RCVR, modemDIS(), > conf.class1RecvIdentTimer, emsg); 89c91 < fxStr& emsg) --- > u_int timer, fxStr& emsg) 91c93,94 < u_int t1 = howmany(conf.t1Timer, 1000); // T1 timer in seconds --- > u_int t1 = howmany(timer, 1000); // in seconds > u_int trecovery = howmany(conf.class1TrainingRecovery, 1000); 95,103c98,106 < emsg = ""; < do { < /* < * Transmit (NSF) (CSI) DIS frames when the receiving < * station or (NSC) (CIG) DTC when initiating a poll. < */ < startTimeout(3000); < fxBool framesSent = sendFrame(f1, id, FALSE); < stopTimeout("sending id frame"); --- > emsg = "No answer (T.30 T1 timeout)"; > /* > * Transmit (NSF) (CSI) DIS frames when the receiving > * station or (NSC) (CIG) DTC when initiating a poll. > */ > startTimeout(3000); > fxBool framesSent = sendFrame(f1, id, FALSE); > stopTimeout("sending id frame"); > for (;;) { 127c130,131 < if (recvTraining()) --- > if (recvTraining()) { > emsg = ""; 128a133 > } 129a135,144 > /* > * Reset the timeout to insure the T1 timer is > * used. This is done because the adaptive answer > * strategy may setup a shorter timeout that's > * used to wait for the initial identification > * frame. If we get here then we know the remote > * side is a fax machine and so we should wait > * the full T1 timeout, as specified by the protocol. > */ > t1 = howmany(conf.t1Timer, 1000); 134,139c149,151 < * If we failed to send our frames or failed to < * receive DCS from the other side, then delay < * long enough to miss any training that the other < * side might have sent us. Otherwise the caller < * will miss our retransmission since it'll be < * in the process of sending training. --- > * We failed to send our frames or failed to receive > * DCS from the other side. First verify there is > * time to make another attempt... 140a153,160 > if (time(0)+trecovery-start >= t1) > break; > /* > * Delay long enough to miss any training that the > * other side might have sent us. Otherwise the > * caller will miss our retransmission since it'll > * be in the process of sending training. > */ 142,144c162,166 < } while (time(0)-start < t1 && class1Cmd("TH", 3, AT_CONNECT)); < if (emsg == "") < emsg = "No answer (T.30 T1 timeout)"; --- > /* > * Retransmit ident frames. > */ > framesSent = transmitFrame(f1, id, FALSE); > } EOF-EOF-EOF Patch faxd/Class1Send.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Class1Send.c++,v 1.39 93/05/10 17:48:22 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Class1Send.c++,v 1.41 93/06/23 12:03:39 sam Exp $ 180,182c180,181 < * parameters. The pfm is the post-file-message < * to use as the post-page-message after sending < * the last page of the file. --- > * parameters. The pph is the post-page-handling > * indicators calculated prior to intiating the call. 185c184 < Class1Modem::sendPhaseB(TIFF* tif, Class2Params& next, u_int pfm, fxStr& emsg) --- > Class1Modem::sendPhaseB(TIFF* tif, Class2Params& next, fxStr& pph, fxStr& emsg) 221c220,230 < int cmd = (morePages ? FCF_MPS : modemPFMCodes[pfm&7]); --- > int cmd; > // XXX check pph length > switch (pph[0]) { > default: > morePages = FALSE; > emsg = "Unknown post-page-handling indicator \"" | pph | "\""; > /* fall thru... */ > case 'P': cmd = FCF_EOP; break; > case 'M': cmd = FCF_EOM; break; > case 'S': cmd = FCF_MPS; break; > } 240a250 > protoTrace("SEND send %s", ppmNames[cmd&0xf]); 256a267 > pph.remove(0); // discard post-page-handling EOF-EOF-EOF Patch faxd/Class2.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Class2.h,v 1.45 93/04/10 11:38:23 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Class2.h,v 1.46 93/05/25 17:34:14 sam Exp $ 101c101 < fxBool sendPhaseB(TIFF* tif, Class2Params&, u_int pfm, fxStr& emsg); --- > fxBool sendPhaseB(TIFF* tif, Class2Params&, fxStr& pph, fxStr& emsg); EOF-EOF-EOF Patch faxd/Class2Params.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Class2Params.c++,v 1.8 93/03/17 14:11:35 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Class2Params.c++,v 1.9 93/06/22 18:19:51 sam Exp $ 204a205,214 > u_int Class2Params::stDCSTab[8] = { > DISMINSCAN_0MS<<1, // ST_0MS > DISMINSCAN_5MS<<1, // ST_5MS > DISMINSCAN_10MS<<1, // ST_10MS2 > DISMINSCAN_10MS<<1, // ST_10MS > DISMINSCAN_20MS<<1, // ST_20MS2 > DISMINSCAN_20MS<<1, // ST_20MS > DISMINSCAN_40MS<<1, // ST_40MS2 > DISMINSCAN_40MS<<1, // ST_40MS > }; 333c343 < | stDISTab[st&7] --- > | stDCSTab[st&7] EOF-EOF-EOF Patch faxd/Class2Params.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Class2Params.h,v 1.5 93/03/12 11:21:58 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Class2Params.h,v 1.6 93/06/22 18:19:34 sam Exp $ 48c48,49 < static u_int stDISTab[8]; // min scanline time --- > static u_int stDISTab[8]; // min scanline time (DIS specific) > static u_int stDCSTab[8]; // min scanline time (DCS specific) EOF-EOF-EOF Patch faxd/Class2Send.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Class2Send.c++,v 1.53 93/03/25 15:14:05 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Class2Send.c++,v 1.55 93/06/21 12:46:01 sam Exp $ 55a56,59 > case AT_OTHER: > if (streq(rbuf, "CED", 3)) // hack for busted modems > return (dialResponse()); > break; 127,129c131,132 < * parameters. The pfm is the post-file-message < * to use as the post-page-message after sending < * the last page of the file. --- > * parameters. The pph is the post-page-handling > * indicators calculated prior to intiating the call. 132c135 < Class2Modem::sendPhaseB(TIFF* tif, Class2Params& next, u_int pfm, fxStr& emsg) --- > Class2Modem::sendPhaseB(TIFF* tif, Class2Params& next, fxStr& pph, fxStr& emsg) 170a174,184 > u_int ppm; > // XXX check pph length > switch (pph[0]) { > default: > morePages = FALSE; > emsg = "Unknown post-page-handling indicator \"" | pph | "\""; > /* fall thru... */ > case 'P': ppm = PPM_EOP; break; > case 'M': ppm = PPM_EOM; break; > case 'S': ppm = PPM_MPS; break; > } 172c186 < if (pageDone(morePages ? PPM_MPS : pfm, ppr)) { --- > if (pageDone(ppm, ppr)) { 177a192 > pph.remove(0); // discard post-page-handling EOF-EOF-EOF Patch faxd/DialRules.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/DialRules.c++,v 1.7 93/05/16 16:19:26 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/DialRules.c++,v 1.8 93/06/20 19:14:05 sam Exp $ 269c269 < v.remove(i); --- > v.remove(i), n--; EOF-EOF-EOF Patch faxd/Everex.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/Everex.h,v 1.36 93/05/10 09:26:45 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/Everex.h,v 1.37 93/05/25 17:34:16 sam Exp $ 102c102 < fxBool sendPhaseB(TIFF* tif, Class2Params&, u_int pfm, fxStr& emsg); --- > fxBool sendPhaseB(TIFF* tif, Class2Params&, fxStr& pph, fxStr& emsg); EOF-EOF-EOF Patch faxd/EverexSend.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/EverexSend.c++,v 1.45 93/03/25 15:14:20 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/EverexSend.c++,v 1.46 93/05/25 17:34:17 sam Exp $ 140,142c140,141 < * parameters. The pfm is the post-file-message < * to use as the post-page-message after sending < * the last page of the file. --- > * parameters. The pph is the post-page-handling > * indicators calculated prior to intiating the call. 145c144 < EverexModem::sendPhaseB(TIFF* tif, Class2Params& next, u_int pfm, fxStr& emsg) --- > EverexModem::sendPhaseB(TIFF* tif, Class2Params& next, fxStr& pph, fxStr& emsg) 177c176,186 < int cmd = (morePages ? FCF_MPS : modemPFMCodes[pfm&7]); --- > int cmd; > // XXX check pph length > switch (pph[0]) { > default: > morePages = FALSE; > emsg = "Unknown post-page-handling indicator \"" | pph | "\""; > /* fall thru... */ > case 'P': cmd = FCF_EOP; break; > case 'M': cmd = FCF_EOM; break; > case 'S': cmd = FCF_MPS; break; > } 191a201 > pph.remove(0); // discard post-page-handling EOF-EOF-EOF Patch faxd/FaxModem.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxModem.c++,v 1.73 93/05/10 16:25:40 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxModem.c++,v 1.75 93/06/22 18:21:08 sam Exp $ 291,293c291,294 < if (atype != ANSTYPE_ANY && conf.answerCmd[atype] == "") < atype = ANSTYPE_ANY; < if (atCmd(conf.answerCmd[atype], AT_NOTHING)) { --- > AnswerType t = atype; > if (t != ANSTYPE_ANY && conf.answerCmd[t] == "") > t = ANSTYPE_ANY; > if (atCmd(conf.answerCmd[t], AT_NOTHING)) { 294a296,309 > if (ctype == CALLTYPE_UNKNOWN) { > /* > * The response does not uniquely identify the type > * of call; assume the type corresponds to the type > * of the answer request. > */ > static CallType unknownCall[] = { > CALLTYPE_FAX, // ANSTYPE_ANY (default) > CALLTYPE_DATA, // ANSTYPE_DATA > CALLTYPE_FAX, // ANSTYPE_FAX > CALLTYPE_VOICE, // ANSTYPE_VOICE > }; > ctype = unknownCall[atype]; > } 902c917 < if (atCmd(conf.softResetCmd, AT_OK, 3)) --- > if (atCmd(conf.softResetCmd, AT_OK, conf.resetDelay)) EOF-EOF-EOF Patch faxd/FaxModem.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxModem.h,v 1.63 93/05/10 16:24:58 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxModem.h,v 1.65 93/06/22 18:20:27 sam Exp $ 82a83 > CALLTYPE_UNKNOWN = 4, // unknown variety 313c314 < * The post file message parameter to sendPhaseB enables the --- > * The post page handling parameter to sendPhaseB enables the 323c324 < virtual fxBool sendPhaseB(TIFF*, Class2Params&, u_int pfm, fxStr& emsg) = 0; --- > virtual fxBool sendPhaseB(TIFF*, Class2Params&, fxStr& pph, fxStr& emsg) = 0; EOF-EOF-EOF Patch faxd/FaxRecv.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRecv.c++,v 1.52 93/04/19 08:32:03 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRecv.c++,v 1.53 93/06/22 18:21:46 sam Exp $ 45c45 < void --- > fxBool 54a55,56 > fxBool faxRecognized = FALSE; > 63c65 < if (modem->recvBegin(emsg)) { --- > if (faxRecognized = modem->recvBegin(emsg)) { 67c69 < } else --- > } else { 68a71,72 > TIFFClose(tif); > } 70d73 < modem->hangup(); 87a91 > return (faxRecognized); EOF-EOF-EOF Patch faxd/FaxRecvInfo.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRecvInfo.c++,v 1.1 93/03/26 10:14:29 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRecvInfo.c++,v 1.2 93/05/25 17:31:33 sam Exp $ 30c30 < fxIMPLEMENT_Array(FaxRecvInfoArray, FaxRecvInfo); --- > fxIMPLEMENT_ObjArray(FaxRecvInfoArray, FaxRecvInfo); EOF-EOF-EOF Patch faxd/FaxRecvInfo.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRecvInfo.h,v 1.9 93/03/26 10:15:40 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRecvInfo.h,v 1.10 93/05/25 17:31:15 sam Exp $ 35c35,36 < struct FaxRecvInfo { --- > class FaxRecvInfo : public fxObj { > public: 50c51 < fxDECLARE_Array(FaxRecvInfoArray, FaxRecvInfo); --- > fxDECLARE_ObjArray(FaxRecvInfoArray, FaxRecvInfo); EOF-EOF-EOF RmFile faxd/FaxRecvdData.c++ Patch faxd/FaxRequest.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRequest.c++,v 1.30 93/05/03 12:10:29 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRequest.c++,v 1.31 93/05/25 17:34:19 sam Exp $ 143a144,145 > } else if (isCmd("pagehandling")) {// page analysis info > pagehandling = tag; 218a221 > fprintf(fp, "pagehandling:%s\n", (char*) pagehandling); EOF-EOF-EOF Patch faxd/FaxRequest.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRequest.h,v 1.24 93/05/03 12:10:33 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxRequest.h,v 1.25 93/05/25 17:34:20 sam Exp $ 88a89 > fxStr pagehandling; // page analysis information EOF-EOF-EOF RmFile faxd/FaxRequestData.c++ Patch faxd/FaxSend.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxSend.c++,v 1.73 93/05/04 13:19:03 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxSend.c++,v 1.74 93/05/25 17:34:21 sam Exp $ 58,60c58,64 < * Construct the phone number to dial by crafting the < * canonical form (+), and < * preparing the form to use in dialing the telephone. --- > * Prepare the job for transmission by analysing > * the page characteristics and determining whether > * or not the page transfer parameters will have > * to be renegotiated after the page is sent. This > * is done before the call is placed because it can > * be slow and there can be timing problems if this > * is done during transmission. 62,68c66,81 < fxStr canon = canonicalizePhoneNumber(fax.number); < fxStr dial = prepareDialString(fax.number); < log = new FaxMachineLog(canon); < setServerStatus("Sending job %s to %s", < (char*) fax.jobid, (char*) canon); < sendFax(fax, dial, canon); < delete log, log = NULL; --- > fxStr emsg; > if (sendPrepareFax(fax, emsg)) { > /* > * Construct the phone number to dial by crafting the > * canonical form (+), and > * preparing the form to use in dialing the telephone. > */ > fxStr canon = canonicalizePhoneNumber(fax.number); > fxStr dial = prepareDialString(fax.number); > log = new FaxMachineLog(canon); > setServerStatus("Sending job %s to %s", > (char*) fax.jobid, (char*) canon); > sendFax(fax, dial, canon); > delete log, log = NULL; > } else > sendFailed(fax, send_failed, emsg); 174,178c187 < // NB: all files are coalesced into a single fax document < u_int pfm = (i < fax.ops.length()-1 && < fax.ops.find(op, i+1) != fx_invalidArrayIndex) ? < PPM_MPS : PPM_EOP; < if (!sendFaxPhaseB(fax, fax.files[i], pfm)) --- > if (!sendFaxPhaseB(fax, fax.files[i])) 300c309 < FaxServer::sendFaxPhaseB(FaxRequest& fax, const fxStr& file, u_int pfm) --- > FaxServer::sendFaxPhaseB(FaxRequest& fax, const fxStr& file) 316c325,326 < status = modem->sendPhaseB(tif, clientParams, pfm, fax.notice); --- > status = modem->sendPhaseB(tif, clientParams, > fax.pagehandling, fax.notice); 410a421,497 > * Prepare the job for transmission by analysing > * the page characteristics and determining whether > * or not the page transfer parameters will have > * to be renegotiated after the page is sent. This > * is done before the call is placed because it can > * be slow and there can be timing problems if this > * is done during transmission. > */ > fxBool > FaxServer::sendPrepareFax(FaxRequest& fax, fxStr& emsg) > { > if (fax.pagehandling != "") // already done > return (TRUE); > /* > * Scan the pages and figure out where session parameters > * will need to be renegotiated. Construct a string of > * indicators to use when doing the actual transmission. > * > * NB: all files are coalesced into a single fax document > * if possible > */ > Class2Params params; // current parameters > Class2Params next; // parameters for next page > TIFF* tif = NULL; // current open TIFF image > params.df = (u_int) -1; // indicates first page > for (u_int i = 0;;) { > if (!tif || TIFFLastDirectory(tif)) { > /* > * Locate the next file to be sent. > */ > if (tif) // close previous file > TIFFClose(tif), tif = NULL; > if (i >= fax.ops.length()) > goto done; > FaxSendOp op = send_tiff; > i = fax.ops.find(op, i); > if (i == fx_invalidArrayIndex) > goto done; > tif = TIFFOpen(fax.files[i], "r"); > if (tif == NULL) { > emsg = "Can not open document file"; > goto bad; > } > i++; // advance for next find > } else { > /* > * Read the next TIFF directory. > */ > if (!TIFFReadDirectory(tif)) { > emsg = "Problem reading document directory"; > goto bad; > } > } > next = params; > if (!sendSetupParams1(tif, next, emsg)) > goto bad; > if (params.df != (u_int) -1) { > /* > * The pagehandling string has: > * 'M' = EOM, for when parameters must be renegotiated > * 'S' = MPS, for when next page uses the same parameters > * 'P' = EOP, for the last page to be transmitted > */ > fax.pagehandling.append(next == params ? 'S' : 'M'); > } > params = next; > } > done: > fax.pagehandling.append('P'); // EOP > return (TRUE); > bad: > if (tif) > TIFFClose(tif); > return (FALSE); > } > > /* 424c511 < FaxServer::sendSetupParams(TIFF* tif, Class2Params& params, fxStr& emsg) --- > FaxServer::sendSetupParams1(TIFF* tif, Class2Params& params, fxStr& emsg) 519,527d605 < < traceStatus(FAXTRACE_PROTOCOL, "USE %s", < Class2Params::pageWidthNames[params.wd]); < traceStatus(FAXTRACE_PROTOCOL, "USE %s", < Class2Params::pageLengthNames[params.ln]); < traceStatus(FAXTRACE_PROTOCOL, "USE %s", < Class2Params::vresNames[params.vr]); < traceStatus(FAXTRACE_PROTOCOL, "USE %s", < Class2Params::dataFormatNames[params.df]); 528a607,623 > } > > fxBool > FaxServer::sendSetupParams(TIFF* tif, Class2Params& params, fxStr& emsg) > { > if (sendSetupParams1(tif, params, emsg)) { > traceStatus(FAXTRACE_PROTOCOL, "USE %s", > Class2Params::pageWidthNames[params.wd]); > traceStatus(FAXTRACE_PROTOCOL, "USE %s", > Class2Params::pageLengthNames[params.ln]); > traceStatus(FAXTRACE_PROTOCOL, "USE %s", > Class2Params::vresNames[params.vr]); > traceStatus(FAXTRACE_PROTOCOL, "USE %s", > Class2Params::dataFormatNames[params.df]); > return (TRUE); > } else > return (FALSE); EOF-EOF-EOF Patch faxd/FaxServer.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxServer.c++,v 1.115 93/05/20 11:02:05 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxServer.c++,v 1.116 93/06/23 12:07:20 sam Exp $ 115a116,118 > adaptiveAnswer = FALSE; // don't answer data if fax answer fails > answerBias = -1; > setAnswerRotary("any"); 621c624 < FaxServer::answerPhone(AnswerType type, fxBool force) --- > FaxServer::answerPhone(AnswerType atype, fxBool force) 628,654c631,653 < switch (modem->answerCall(type, emsg)) { < case FaxModem::CALLTYPE_FAX: < traceStatus(FAXTRACE_SERVER, "ANSWER: FAX CONNECTION"); < recvFax(); < break; < case FaxModem::CALLTYPE_DATA: < traceStatus(FAXTRACE_SERVER, "ANSWER: DATA CONNECTION"); < // fork getty to handle data connection < if (gettyArgs != "") { < if (modem->dataService()) { < if (runGetty(gettyArgs)) { < delete log, log = NULL; < return; // NB: don't unlock until getty exits < } < } else < traceStatus(FAXTRACE_SERVER, < "ANSWER: Could not switch modem to data service"); < } else < traceStatus(FAXTRACE_SERVER, < "ANSWER: Data connections are not permitted"); < break; < case FaxModem::CALLTYPE_VOICE: < traceStatus(FAXTRACE_SERVER, "ANSWER: VOICE CONNECTION"); < break; < case FaxModem::CALLTYPE_ERROR: < traceStatus(FAXTRACE_SERVER, "ANSWER: %s", (char*) emsg); < break; --- > /* > * If requested, rotate the way we answer the phone > * if the request type is "any". This should probably > * only be used if the modem does not directly support > * adaptive-answer. > */ > if (atype == FaxModem::ANSTYPE_ANY) > atype = answerRotary[answerRotor]; > CallType ctype = modem->answerCall(atype, emsg); > fxBool waitForProcess; > fxBool callSetup = setupCall(atype, ctype, waitForProcess, emsg); > if (!callSetup && ctype == FaxModem::CALLTYPE_FAX && adaptiveAnswer) { > /* > * Status indicated a call from a fax machine, but we > * were unable to complete the initial handshake. > * If we are doing adaptive answer, immediately > * retry answering the call as data w/o hanging up > * the phone (note that this depends on characteristics > * of the local phone system). > */ > atype = FaxModem::ANSTYPE_DATA; > ctype = modem->answerCall(atype, emsg); > callSetup = setupCall(atype, ctype, waitForProcess, emsg); 655a655,676 > /* > * Call resolved. If we were able to recognize the call > * type and setup a session, then reset the answer rotary > * state if there is a bias toward a specific answer type. > * Also, deal with call types that are processed through > * a subprocess, rather than within this process. Otherwise, > * if the call failed, advance the rotor to the next answer > * type in preparation for the next call. > */ > if (callSetup) { > if (answerBias >= 0) > answerRotor = answerBias; > /* > * Some calls are handled by starting up a subprocess > * that does the work. For such calls we have to wait > * for the process to exit before we can remove the > * lock file and do related cleanup work. > */ > if (waitForProcess) > return; > } else > answerRotor = (answerRotor+1) % answerRotorSize; 689a711,776 > * Do setup after answering an incoming call. > */ > fxBool > FaxServer::setupCall(AnswerType atype, CallType ctype, fxBool& waitForProcess, > fxStr& emsg) > { > fxBool callSetup = FALSE; > waitForProcess = FALSE; > > switch (ctype) { > case FaxModem::CALLTYPE_FAX: > traceStatus(FAXTRACE_SERVER, "ANSWER: FAX CONNECTION"); > callSetup = recvFax(); > break; > case FaxModem::CALLTYPE_DATA: > traceStatus(FAXTRACE_SERVER, "ANSWER: DATA CONNECTION"); > if (gettyArgs == "") { > traceStatus(FAXTRACE_SERVER, > "ANSWER: Data connections are not permitted"); > break; > } > /* > * If call was answered using an adaptive-answering > * facility, then give the modem an opportunity to > * establish data services. > */ > if (atype == FaxModem::ANSTYPE_ANY && !modem->dataService()) { > traceStatus(FAXTRACE_SERVER, > "ANSWER: Could not switch modem to data service"); > break; > } > /* > * Fork and exec a getty process to handle the > * data connection. Note that we return without > * removing our lock on the modem--this is done > * after we reap the child getty process to insure > * outgoing modem use is disallowed. > */ > if (runGetty(gettyArgs)) { > delete log, log = NULL; > callSetup = TRUE; > waitForProcess = TRUE; > } > break; > case FaxModem::CALLTYPE_VOICE: > traceStatus(FAXTRACE_SERVER, "ANSWER: VOICE CONNECTION"); > /* > * If call was answered using an adaptive-answering > * facility, then give the modem an opportunity to > * establish voice services. > */ > if (atype == FaxModem::ANSTYPE_ANY && !modem->voiceService()) { > traceStatus(FAXTRACE_SERVER, > "ANSWER: Could not switch modem to voice service"); > break; > } > // XXX setup voice process a la getty > break; > case FaxModem::CALLTYPE_ERROR: > traceStatus(FAXTRACE_SERVER, "ANSWER: %s", (char*) emsg); > break; > } > return (callSetup); > } > > /* 876a964,972 > static fxBool > getbool(const char* cp) > { > return (streq(cp, "on") || streq(cp, "yes")); > } > > /* > * Process an answer rotary spec string. > */ 877a974,999 > FaxServer::setAnswerRotary(const fxStr& value) > { > u_int l = 0; > for (u_int i = 0; i < 3 && l < value.length(); i++) { > fxStr type(value.token(l, " \t")); > type.raisecase(); > if (type == "FAX") > answerRotary[i] = FaxModem::ANSTYPE_FAX; > else if (type == "DATA") > answerRotary[i] = FaxModem::ANSTYPE_DATA; > else if (type == "VOICE") > answerRotary[i] = FaxModem::ANSTYPE_VOICE; > else { > if (type != "ANY") > traceStatus(FAXTRACE_SERVER, > "Unknown answer type \"%s\"", (char*) type); > answerRotary[i] = FaxModem::ANSTYPE_ANY; > } > } > if (i == 0) // void string > answerRotary[i++] = FaxModem::ANSTYPE_ANY; > answerRotor = 0; > answerRotorSize = i; > } > > void 953a1076,1079 > else if (streq(tag, "adaptiveanswer")) adaptiveAnswer = getbool(value); > else if (streq(tag, "answerrotary")) setAnswerRotary(value); > else if (streq(tag, "answerbias")) > answerBias = fxmin(getnum(value),2); EOF-EOF-EOF Patch faxd/FaxServer.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/FaxServer.h,v 1.80 93/05/10 09:26:48 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/FaxServer.h,v 1.82 93/06/23 12:04:20 sam Exp $ 53c53 < const long TIMER_POLLGETTY = 60; // poll getty done once a minute --- > const long TIMER_POLLGETTY = 30; // poll getty done twice a minute 96a97,101 > fxBool adaptiveAnswer; // answer as data if fax answer fails > short answerBias; // rotor bias applied after good calls > u_short answerRotor; // rotor into possible selections > u_short answerRotorSize; // rotor table size > AnswerType answerRotary[3]; // rotary selection of answer types 132a138 > fxBool sendPrepareFax(FaxRequest& fax, fxStr& emsg); 134c140 < fxBool sendFaxPhaseB(FaxRequest& fax, const fxStr& file, u_int pfm); --- > fxBool sendFaxPhaseB(FaxRequest& fax, const fxStr& file); 136a143 > fxBool sendSetupParams1(TIFF*, Class2Params&, fxStr& emsg); 140c147 < void recvFax(); --- > fxBool recvFax(); 149c156,158 < // data connection support --- > // miscellaneous stuff > fxBool setupCall(AnswerType atype, CallType ctype, > fxBool& waitForProcess, fxStr& emsg); 150a160 > void setAnswerRotary(const fxStr& value); EOF-EOF-EOF Patch faxd/ModemConfig.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/ModemConfig.c++,v 1.17 93/05/10 16:27:22 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/ModemConfig.c++,v 1.18 93/06/22 18:20:16 sam Exp $ 96a97 > class1RecvIdentTimer = t1Timer; // default to standard protocol 152d152 < 230a231,232 > else if (streq(tag, "Class1RecvIdentTimer")) > class1RecvIdentTimer = atoi(value); EOF-EOF-EOF Patch faxd/ModemConfig.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/faxd/RCS/ModemConfig.h,v 1.15 93/05/10 16:26:49 sam Exp $ --- > /* $Header: /usr/people/sam/fax/faxd/RCS/ModemConfig.h,v 1.16 93/06/22 18:19:57 sam Exp $ 69a70 > u_int class1RecvIdentTimer; // timeout receiving initial identity EOF-EOF-EOF Patch faxd/TODO<<'EOF-EOF-EOF' 1d0 < B must do +FET=1 before changing session parameters in Class 2 driver EOF-EOF-EOF Patch libtiff/Makefile.aix<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.aix,v 1.21 93/04/18 18:05:18 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.aix,v 1.21 93/04/18 18:05:18 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.apollo<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.apollo,v 1.35 93/04/18 18:05:18 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.apollo,v 1.35 93/04/18 18:05:18 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.gcc<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.gcc,v 1.4 93/04/18 18:05:19 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.gcc,v 1.4 93/04/18 18:05:19 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.hpux<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.hpux,v 1.34 93/04/18 18:05:20 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.hpux,v 1.34 93/04/18 18:05:20 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.mips<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.mips,v 1.33 93/04/18 18:05:20 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.mips,v 1.33 93/04/18 18:05:20 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.mpw<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.mpw,v 1.3 93/04/18 18:05:21 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.mpw,v 1.3 93/04/18 18:05:21 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.next<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.next,v 1.34 93/04/18 18:05:22 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.next,v 1.34 93/04/18 18:05:22 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.sco<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.sco,v 1.4 93/04/18 18:05:22 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.sco,v 1.4 93/04/18 18:05:22 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.sgi<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.sgi,v 1.54 93/04/18 18:05:23 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.sgi,v 1.54 93/04/18 18:05:23 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.sun<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.sun,v 1.45 93/04/18 18:05:24 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.sun,v 1.45 93/04/18 18:05:24 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.tahoe<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.tahoe,v 1.36 93/04/18 18:05:24 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.tahoe,v 1.36 93/04/18 18:05:24 sam Exp $ EOF-EOF-EOF Patch libtiff/Makefile.vax<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.vax,v 1.46 93/04/18 18:05:25 sam Exp $ --- > # $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.vax,v 1.46 93/04/18 18:05:25 sam Exp $ EOF-EOF-EOF Patch libtiff/README<<'EOF-EOF-EOF' 1c1 < $Header: /usr/people/sam/tiff/libtiff/RCS/README,v 1.16 92/10/21 16:37:31 sam Exp $ --- > $Header: /usr/people/sam/tiff/libtiff/RCS/README,v 1.16 92/10/21 16:37:31 sam Rel $ EOF-EOF-EOF Patch libtiff/mkg3states.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/mkg3states.c,v 1.15 93/02/14 10:15:25 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/mkg3states.c,v 1.15 93/02/14 10:15:25 sam Rel $"; 46c46 < * Reference: $Id: mkg3states.c,v 1.15 93/02/14 10:15:25 sam Exp $ --- > * Reference: $Id: mkg3states.c,v 1.15 93/02/14 10:15:25 sam Rel $ EOF-EOF-EOF Patch libtiff/mkspans.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/mkspans.c,v 1.6 92/10/21 14:16:20 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/mkspans.c,v 1.6 92/10/21 14:16:20 sam Rel $"; EOF-EOF-EOF Patch libtiff/t4.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/tiff/libtiff/RCS/t4.h,v 1.9 92/02/10 19:06:22 sam Exp $ */ --- > /* $Header: /usr/people/sam/tiff/libtiff/RCS/t4.h,v 1.9 92/02/10 19:06:22 sam Rel $ */ EOF-EOF-EOF Patch libtiff/tif_apple.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_apple.c,v 1.10 92/10/30 11:43:23 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_apple.c,v 1.10 92/10/30 11:43:23 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_aux.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_aux.c,v 1.17 92/11/27 11:41:30 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_aux.c,v 1.17 92/11/27 11:41:30 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_ccittrle.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_ccittrle.c,v 1.16 92/10/21 13:42:04 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_ccittrle.c,v 1.16 92/10/21 13:42:04 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_close.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_close.c,v 1.22 92/10/21 13:42:04 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_close.c,v 1.22 92/10/21 13:42:04 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_compress.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_compress.c,v 1.32 92/10/23 09:45:12 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_compress.c,v 1.32 92/10/23 09:45:12 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_dirinfo.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirinfo.c,v 1.22 92/11/09 11:10:18 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirinfo.c,v 1.22 92/11/09 11:10:18 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_dirwrite.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirwrite.c,v 1.27 93/02/27 09:28:23 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirwrite.c,v 1.27 93/02/27 09:28:23 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_dumpmode.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dumpmode.c,v 1.29 92/10/26 17:08:41 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dumpmode.c,v 1.29 92/10/26 17:08:41 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_error.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_error.c,v 1.15 92/10/21 13:42:09 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_error.c,v 1.15 92/10/21 13:42:09 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_flush.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_flush.c,v 1.16 92/10/21 13:42:11 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_flush.c,v 1.16 92/10/21 13:42:11 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_jpeg.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_jpeg.c,v 1.6 92/10/21 13:42:12 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_jpeg.c,v 1.6 92/10/21 13:42:12 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_lzw.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_lzw.c,v 1.46 93/01/28 16:59:24 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_lzw.c,v 1.46 93/01/28 16:59:24 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_machdep.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_machdep.c,v 1.4 92/10/21 13:42:14 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_machdep.c,v 1.4 92/10/21 13:42:14 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_msdos.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_msdos.c,v 1.5 92/11/09 11:00:23 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_msdos.c,v 1.5 92/11/09 11:00:23 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_next.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_next.c,v 1.18 92/10/21 16:36:23 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_next.c,v 1.18 92/10/21 16:36:23 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_open.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_open.c,v 1.39 92/10/21 14:16:48 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_open.c,v 1.39 92/10/21 14:16:48 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_packbits.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_packbits.c,v 1.29 92/10/26 17:08:54 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_packbits.c,v 1.29 92/10/26 17:08:54 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_print.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_print.c,v 1.46 92/10/21 13:42:17 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_print.c,v 1.46 92/10/21 13:42:17 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_strip.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_strip.c,v 1.9 92/10/21 13:42:18 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_strip.c,v 1.9 92/10/21 13:42:18 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_swab.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_swab.c,v 1.16 92/10/23 11:13:11 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_swab.c,v 1.16 92/10/23 11:13:11 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_thunder.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_thunder.c,v 1.21 92/10/21 13:42:20 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_thunder.c,v 1.21 92/10/21 13:42:20 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_tile.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_tile.c,v 1.12 92/10/21 13:42:20 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_tile.c,v 1.12 92/10/21 13:42:20 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_unix.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_unix.c,v 1.4 92/10/21 13:42:21 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_unix.c,v 1.4 92/10/21 13:42:21 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_vms.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_vms.c,v 1.6 92/10/21 13:42:22 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_vms.c,v 1.6 92/10/21 13:42:22 sam Rel $"; EOF-EOF-EOF Patch libtiff/tif_warning.c<<'EOF-EOF-EOF' 2c2 < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_warning.c,v 1.15 92/10/21 13:42:23 sam Exp $"; --- > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_warning.c,v 1.15 92/10/21 13:42:23 sam Rel $"; EOF-EOF-EOF Patch libtiff/tiff.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiff.h,v 1.37 92/08/04 12:27:17 sam Exp $ */ --- > /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiff.h,v 1.37 92/08/04 12:27:17 sam Rel $ */ EOF-EOF-EOF Patch libtiff/tiffcomp.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffcomp.h,v 1.32 92/10/30 11:43:31 sam Exp $ */ --- > /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffcomp.h,v 1.32 92/10/30 11:43:31 sam Rel $ */ EOF-EOF-EOF Patch libtiff/tiffconf.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffconf.h,v 1.2 92/11/09 11:10:08 sam Exp $ */ --- > /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffconf.h,v 1.2 92/11/09 11:10:08 sam Rel $ */ EOF-EOF-EOF Patch man/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/man/RCS/Makefile,v 1.17 93/05/19 11:33:36 sam Exp $ --- > # $Header: /usr/people/sam/fax/man/RCS/Makefile,v 1.18 93/06/18 11:45:17 sam Exp $ 54,55c54,55 < -e 's;\$${LIBDATA};${LIB};g'\ < -e 's;\$${LIBEXEC};${LIB};g'\ --- > -e 's;\$${LIBDATA};${LIBDATA};g'\ > -e 's;\$${LIBEXEC};${LIBEXEC};g'\ EOF-EOF-EOF Patch man/config.4f<<'EOF-EOF-EOF' 1c1 < .\" $Header: /usr/people/sam/fax/man/RCS/config.4f,v 1.20 93/05/19 11:33:47 sam Exp $ --- > .\" $Header: /usr/people/sam/fax/man/RCS/config.4f,v 1.21 93/06/25 14:10:49 sam Exp $ 27c27 < .TH CONFIG 4F "May 12, 1993" --- > .TH CONFIG 4F "June 24, 1993" 91a92,94 > AdaptiveAnswer boolean \s-1No\s+1 enable adaptive answer of inbound calls > AnswerRotary string \s-1any\s+1 alternatives for answering calls > AnswerBias integer -1 bias to apply to successful rotary answer 154a158,159 > Class1RecvAbortOK integer \s-1100\s+1 Class 1: max wait (ms) for ``\s-1OK\s+1'' after recv abort > Class1RecvIdentTimer integer \s-135000\s+1 Class 1: max wait (ms) for initial ident frame 159d163 < Class1RecvAbortOK integer \s-1100\s+1 Class 1: max wait (ms) for ``\s-1OK\s+1'' after recv abort 173a178,247 > .B AdaptiveAnswer > Control whether or not an adaptive answering > strategy is used whereby an incoming call is > first answered as fax using > .B ModemAnswerFaxCmd > and then, if that fails, as data using > .BR ModemAnswerDataCmd . > If the adaptive answer strategy is not enabled, then calls > are answered using the appropriate > .B ModemAnswer*Cmd > parameter (normally > .B ModemAnswerCmd > for unattended operation). > Note that the adaptive answer strategy depends on many factors > that limit its usefulness. > It typically only works with a Class 1 modem because it is > important that the sequence of operations related to answering > as fax be completed in a short enough time that a subsequent > answer for data be done before the caller times out and hangs > up the telephone > (for this reason the > .B Class1RecvIdentTimer > should be set to a value that is shorter than the T1 timer.) > Also, note that it is necessary to arrange that the phone be > placed on-hook between the two answers; this can typically be > done by inserting the appropriate command at the start of > .BR ModemAnswerDataCmd . > .TP > .B AnswerRotary > The sequence of answering techniques the server should > ``rotate through'' when answer incoming calls. > Answering techniques are: > .sp .5 > .ta \w'\fBName\fP 'u > .nf > \fBName Description\fP > fax answer a fax call > data answer a data call > voice answer a voice call > any answer a call of any/unknown type > .sp .5 > .fi > When a call is not answered succesfully, the server > advances the rotary to the next specified answering > technique. > Successful calls do not effect the current answering technique. > For example, if > .B AnswerRotary > is ``fax data'', > then the calls will initially be answered as fax until > the first call is received that does not appear to be > from a fax machine; after that calls will be answered > as if they were from a data modem until the next unsuccessful > call; after which they will one again be answered as fax. > See also > .BR AnswerBias . > .TP > .B AnswerBias > The index into the > .B AnswerRotary > list that the server should rotate the list to after > each successfull incoming phone call. > List indices are numbered starting at zero. > For example, if > .B AnswerRotary > is ``fax data'' and > .B AnswerBias > is 1, then after each successful inbound call, the > next call will be answered as data. > .TP 474c548 < for Class 1 and Class 2 modems, but only softare flow control --- > for Class 1 and Class 2 modems, but only software flow control 754a829,856 > .B Class1FrameOverhead > The number of extraneous bytes in > .SM HDLC > frames sent to the host in response to an ``\s-1AT+FRH\s+1'' command. > For modems that properly implement the Class 1 interface, this > number should be 4 (the default). > .TP > .B Class1RecvAbortOK > The time, in milliseconds, to wait for an ``\s-1OK\s+1'' result code > from the modem after aborting an > .SM HDLC > frame receive (``\s-1AT+FRH=3\s+1''). > If this number is zero, then the modem is assumed to not correctly > implement aborting and instead the driver will wait 200ms, > flush any input, and then send ``\s-1AT\en\s+1'' and wait > 100ms for an ``\s-1OK\s+1'' result. > .TP > .B Class1RecvIdentTimer > The time, in milliseconds, to wait for an initial > .SM DCS > when receiving a facsimile. > .SM CCITT > recommendation T.30 specifies this as the value of the T1 timer. > However, adaptive answering schemes such as that described > above under the > .B AdaptiveAnswer > parameter require that this timer be shorter. > .TP 770,779d871 < .TP < .B Class1RecvAbortOK < The time, in milliseconds, to wait for an ``\s-1OK\s+1'' result code < from the modem after aborting an < .SM HDLC < frame receive (``\s-1AT+FRH=3\s+1''). < If this number is zero, then the modem is assumed to not correctly < implement aborting and instead the driver will wait 200ms, < flush any input, and then send ``\s-1AT\en\s+1'' and wait < 100ms for an ``\s-1OK\s+1'' result. EOF-EOF-EOF Patch man/faxcover.1<<'EOF-EOF-EOF' 1c1 < .\" $Header: /usr/people/sam/fax/man/RCS/faxcover.1,v 1.11 93/05/14 15:55:18 sam Exp $ --- > .\" $Header: /usr/people/sam/fax/man/RCS/faxcover.1,v 1.12 93/06/25 14:17:30 sam Exp $ 27c27 < .TH FAXCOVER 1 "May 12, 1993" --- > .TH FAXCOVER 1 "June 25, 1993" 135c135,137 < option. --- > option by specifying a file in the > .B FAXCOVER > environment variable. EOF-EOF-EOF Patch port/386bsd/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/port/386bsd/RCS/Makefile,v 1.4 93/04/27 14:59:39 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/386bsd/RCS/Makefile,v 1.6 93/06/24 10:43:19 sam Exp $ 81,82c81,82 < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${BIN} < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${LIB} --- > ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir \ > ${BIN} ${LIBDATA} ${LIBEXEC} 84c84 < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${BIN} --- > ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${USRETC} EOF-EOF-EOF Patch port/386bsd/defs<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/386bsd/RCS/defs,v 1.14 93/05/17 16:11:48 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/386bsd/RCS/defs,v 1.15 93/06/18 11:46:15 sam Exp $ 160c160,161 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 166c167,168 < LIB= /usr/local/lib/fax --- > LIBDATA=/usr/local/lib/fax > LIBEXEC=/usr/local/lib/fax EOF-EOF-EOF Patch port/4.4bsd/Makefile.flexfax<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/port/4.4bsd/RCS/Makefile.flexfax,v 1.1 93/05/11 10:45:09 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/4.4bsd/RCS/Makefile.flexfax,v 1.3 93/06/24 10:43:34 sam Exp $ 82,83c82,83 < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${BIN} < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${LIB} --- > ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir \ > ${BIN} ${LIBDATA} ${LIBEXEC} 85c85 < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${BIN} --- > ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${USRETC} EOF-EOF-EOF Patch port/4.4bsd/defs<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/4.4bsd/RCS/defs,v 1.2 93/05/17 16:12:29 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/4.4bsd/RCS/defs,v 1.3 93/06/18 11:46:18 sam Exp $ 160c160,161 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 166c167,168 < LIB= /usr/local/lib/fax --- > LIBDATA=/usr/local/lib/fax > LIBEXEC=/usr/local/lib/fax EOF-EOF-EOF Patch port/bsdi/Makefile.flexfax<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/port/bsdi/RCS/Makefile.flexfax,v 1.11 93/04/27 14:58:02 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/bsdi/RCS/Makefile.flexfax,v 1.13 93/06/24 10:43:35 sam Exp $ 82,83c82,83 < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${BIN} < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${LIB} --- > ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir \ > ${BIN} ${LIBDATA} ${LIBEXEC} 85c85 < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${BIN} --- > ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${USRETC} EOF-EOF-EOF Patch port/bsdi/defs<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/bsdi/RCS/defs,v 1.21 93/05/17 16:12:30 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/bsdi/RCS/defs,v 1.22 93/06/18 11:46:18 sam Exp $ 160c160,161 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 166c167,168 < LIB= /usr/local/lib/flexfax --- > LIBDATA=/usr/local/lib/flexfax > LIBEXEC=/usr/local/lib/flexfax EOF-EOF-EOF Patch port/sco/Makefile.flexfax<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/port/sco/RCS/Makefile.flexfax,v 1.3 93/04/27 14:58:07 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/sco/RCS/Makefile.flexfax,v 1.5 93/06/24 10:43:36 sam Exp $ 82,83c82,83 < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${BIN} < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${LIB} --- > ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir \ > ${BIN} ${LIBDATA} ${LIBEXEC} 85c85 < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${BIN} --- > ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${USRETC} EOF-EOF-EOF Patch port/sco/defs<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/sco/RCS/defs,v 1.4 93/04/18 18:06:10 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/sco/RCS/defs,v 1.5 93/06/18 11:46:20 sam Exp $ 159c159,160 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 165c166,167 < LIB=/u/lib/fax --- > LIBDATA=/u/lib/fax > LIBEXEC=/u/lib/fax EOF-EOF-EOF Patch port/sgi/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/port/sgi/RCS/Makefile,v 1.52 93/04/27 14:59:46 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/sgi/RCS/Makefile,v 1.54 93/06/24 10:43:37 sam Exp $ 82,83c82,83 < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${BIN} < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${LIB} --- > ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir \ > ${BIN} ${LIBDATA} ${LIBEXEC} 85c85 < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${BIN} --- > ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${USRETC} EOF-EOF-EOF Patch port/sgi/defs.cc<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/sgi/RCS/defs.cc,v 1.35 93/05/17 16:12:31 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/sgi/RCS/defs.cc,v 1.36 93/06/18 11:46:20 sam Exp $ 161c161,162 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 167c168,169 < LIB= /usr/local/lib/fax --- > LIBDATA=/usr/local/lib/fax > LIBEXEC=/usr/local/lib/fax EOF-EOF-EOF Patch port/sgi/defs.gcc<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/sgi/RCS/defs.gcc,v 1.9 93/05/17 16:12:32 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/sgi/RCS/defs.gcc,v 1.10 93/06/18 11:46:21 sam Exp $ 161c161,162 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 167c168,169 < LIB = /usr/local/lib/fax --- > LIBDATA=/usr/local/lib/fax > LIBEXEC=/usr/local/lib/fax EOF-EOF-EOF Patch port/solaris2/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/port/solaris2/RCS/Makefile,v 1.3 93/04/27 14:59:56 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/solaris2/RCS/Makefile,v 1.5 93/06/24 10:43:38 sam Exp $ 81,82c81,82 < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${BIN} < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${LIB} --- > ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir \ > ${BIN} ${LIBDATA} ${LIBEXEC} 84c84 < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${BIN} --- > ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${USRETC} EOF-EOF-EOF Patch port/solaris2/defs<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/solaris2/RCS/defs,v 1.6 93/04/18 18:06:17 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/solaris2/RCS/defs,v 1.7 93/06/18 11:46:22 sam Exp $ 161c161,162 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 167c168,169 < LIB= /opt/fax/lib --- > LIBDATA=/opt/fax/lib > LIBEXEC=/opt/fax/lib EOF-EOF-EOF Patch port/sun/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/port/sun/RCS/Makefile,v 1.26 93/04/27 14:59:57 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/sun/RCS/Makefile,v 1.28 93/06/24 10:43:38 sam Exp $ 81,82c81,82 < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${BIN} < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${LIB} --- > ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir \ > ${BIN} ${LIBDATA} ${LIBEXEC} 84c84 < ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${BIN} --- > ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${USRETC} EOF-EOF-EOF Patch port/sun/defs<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/sun/RCS/defs,v 1.27 93/05/17 16:12:33 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/sun/RCS/defs,v 1.28 93/06/18 11:46:23 sam Exp $ 153c153,154 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 159c160,161 < LIB= /usr/local/lib/fax --- > LIBDATA=/usr/local/lib/fax > LIBEXEC=/usr/local/lib/fax EOF-EOF-EOF Patch port/svr4/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/port/svr4/RCS/Makefile,v 1.5 93/04/27 14:59:57 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/svr4/RCS/Makefile,v 1.7 93/06/24 10:43:39 sam Exp $ 81,82c81,82 < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${BIN} < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${LIB} --- > ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir \ > ${BIN} ${LIBDATA} ${LIBEXEC} 84c84 < ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${BIN} --- > ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${USRETC} EOF-EOF-EOF Patch port/svr4/defs<<'EOF-EOF-EOF' 1c1 < # $Header: /usr/people/sam/fax/port/svr4/RCS/defs,v 1.11 93/04/18 18:06:21 sam Exp $ --- > # $Header: /usr/people/sam/fax/port/svr4/RCS/defs,v 1.12 93/06/18 11:46:24 sam Exp $ 160c160,161 < # LIB client-directed application library support --- > # LIBDATA client-directed application library data files > # LIBEXEC client-directed application library executables 166c167,168 < LIB= /usr/local/lib/fax --- > LIBDATA=/usr/local/lib/fax > LIBEXEC=/usr/local/lib/fax EOF-EOF-EOF Patch sendfax/sendfax.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/sendfax/RCS/sendfax.c++,v 1.51 93/05/20 10:41:08 sam Exp $ --- > /* $Header: /usr/people/sam/fax/sendfax/RCS/sendfax.c++,v 1.52 93/05/21 11:32:49 sam Exp $ 98d97 < setPageSize("default"); EOF-EOF-EOF Patch sgi2fax/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/sgi2fax/RCS/Makefile,v 1.16 93/05/06 12:02:37 sam Exp $ --- > # $Header: /usr/people/sam/fax/sgi2fax/RCS/Makefile,v 1.17 93/06/18 11:45:08 sam Exp $ 56c56 < ${INSTALL} -F ${LIB} -m 755 -idb ${PRODUCT}.sw.client -O sgi2fax --- > ${INSTALL} -F ${LIBEXEC} -m 755 -idb ${PRODUCT}.sw.client -O sgi2fax EOF-EOF-EOF Patch util/Makefile<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/util/RCS/Makefile,v 1.50 93/05/19 15:50:33 sam Exp $ --- > # $Header: /usr/people/sam/fax/util/RCS/Makefile,v 1.51 93/06/18 11:44:16 sam Exp $ 89,90c89,90 < ${INSTALL} -F ${LIB} -m 755 -idb ${PRODUCT}.sw.client -O textfmt < ${INSTALL} -F ${LIB} -m 444 -idb ${PRODUCT}.sw.client -O \ --- > ${INSTALL} -F ${LIBEXEC} -m 755 -idb ${PRODUCT}.sw.client -O textfmt > ${INSTALL} -F ${LIBDATA} -m 444 -idb ${PRODUCT}.sw.client -O \ EOF-EOF-EOF Patch util/PageSize.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/util/RCS/PageSize.c++,v 1.6 93/05/17 17:03:31 sam Exp $ --- > /* $Header: /usr/people/sam/fax/util/RCS/PageSize.c++,v 1.7 93/06/18 11:44:18 sam Exp $ 79c79 < sprintf(file, "%s/%s", FAX_LIBDIR, FAX_PAGESIZES); --- > sprintf(file, "%s/%s", FAX_LIBDATA, FAX_PAGESIZES); EOF-EOF-EOF Patch util/SendFaxClient.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/util/RCS/SendFaxClient.c++,v 1.5 93/05/20 10:40:48 sam Exp $ --- > /* $Header: /usr/people/sam/fax/util/RCS/SendFaxClient.c++,v 1.8 93/06/18 11:44:20 sam Exp $ 71c71,72 < verbose = FALSE; --- > typeRules = NULL; > files = new FileInfoArray; 73d73 < killtime = "now + 1 day"; // default time to kill the job 74a75,78 > gotPermission = FALSE; > permission = FALSE; > verbose = FALSE; > killtime = "now + 1 day"; // default time to kill the job 77c81,82 < notify = no_notice; // default is no email notification --- > pageWidth = 0; > pageLength = 0; 79d83 < typeRules = NULL; 81c85 < files = new FileInfoArray; --- > notify = no_notice; // default is no email notification 98c102,104 < typeRules = TypeRules::read(fxStr(FAX_LIBDIR) | "/" | TypeRulesFile); --- > if (pageSize == "" && !setPageSize("default")) > return (FALSE); > typeRules = TypeRules::read(fxStr(FAX_LIBDATA) | "/" | TypeRulesFile); 217c223 < void --- > fxBool 221,226c227,236 < if (!info) < fxFatal("Unknown page size \"%s\"", name); < pageWidth = info->width(); < pageLength = info->height(); < pageSize = name; < delete info; --- > if (info) { > pageWidth = info->width(); > pageLength = info->height(); > pageSize = name; > delete info; > return (TRUE); > } else { > printError("Unknown page size \"%s\"", name); > return (FALSE); > } 298,301c308,315 < char hostname[64]; < (void) gethostname(hostname, sizeof (hostname)); < struct hostent* hp = gethostbyname(hostname); < mailbox = fxStr(user) | "@" | (hp ? hp->h_name : hostname); --- > fxStr acct(user); > if (acct.next(0, '@') == acct.length()) { > char hostname[64]; > (void) gethostname(hostname, sizeof (hostname)); > struct hostent* hp = gethostbyname(hostname); > mailbox = acct | "@" | (hp ? hp->h_name : hostname); > } else > mailbox = acct; EOF-EOF-EOF Patch util/SendFaxClient.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/util/RCS/SendFaxClient.h,v 1.3 93/05/20 10:40:59 sam Exp $ --- > /* $Header: /usr/people/sam/fax/util/RCS/SendFaxClient.h,v 1.4 93/05/21 11:36:08 sam Exp $ 136c136 < void setPageSize(const char* name); --- > fxBool setPageSize(const char* name); EOF-EOF-EOF Patch util/TypeRules.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/util/RCS/TypeRules.c++,v 1.11 93/05/02 19:23:42 sam Exp $ --- > /* $Header: /usr/people/sam/fax/util/RCS/TypeRules.c++,v 1.12 93/06/18 11:44:20 sam Exp $ 190c190 < case 'F': fmtd.append(fxStr(FAX_FILTERDIR)); continue; --- > case 'F': fmtd.append(fxStr(FAX_LIBEXEC)); continue; EOF-EOF-EOF Patch util/config.h<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/util/RCS/config.h,v 1.36 93/05/17 15:38:12 sam Exp $ --- > /* $Header: /usr/people/sam/fax/util/RCS/config.h,v 1.37 93/06/18 11:44:21 sam Exp $ 36,37c36,37 < #define FAX_FILTERDIR "/usr/local/lib/fax" /* place for filters */ < #define FAX_LIBDIR "/usr/local/lib/fax" /* place for lib stuff */ --- > #define FAX_LIBEXEC "/usr/local/lib/fax" /* place for lib executables */ > #define FAX_LIBDATA "/usr/local/lib/fax" /* place for lib data files */ EOF-EOF-EOF Patch util/ps2fax.gs.sh<<'EOF-EOF-EOF' 2c2 < # $Header: /usr/people/sam/fax/util/RCS/ps2fax.gs.sh,v 1.7 93/04/18 18:05:55 sam Exp $ --- > # $Header: /usr/people/sam/fax/util/RCS/ps2fax.gs.sh,v 1.8 93/05/23 12:26:20 sam Exp $ 60c60,61 < 1728x280) paper=letter;; --- > # 279.4mm is actually correct, but many people round up! > 1728x280|1728x279) paper=letter;; EOF-EOF-EOF Patch util/textfmt.c++<<'EOF-EOF-EOF' 1c1 < /* $Header: /usr/people/sam/fax/util/RCS/textfmt.c++,v 1.14 93/05/19 15:50:54 sam Exp $ --- > /* $Header: /usr/people/sam/fax/util/RCS/textfmt.c++,v 1.15 93/06/18 11:28:37 sam Exp $ 118a119 > int 271c272 < exit(0); --- > return (0); EOF-EOF-EOF