rsalz@uunet.uu.net (Rich Salz) (01/31/89)
Submitted-by: sau@faline.bellcore.com (Stephen A. Uhler) Posting-number: Volume 17, Issue 63 Archive-name: mgr/patch1 Thank you for sending out MGR, which is winding its way to bellcore as I write this. Several bugs in the distribution were brought to my attention, so I am sending you the bug fixes. One bug is serious, as it prevents MGR from running at all on release 4.0 suns (it has a 1 line fix though). -Stephen A Uhler (sau@bellcore.com) NOTES: "mgr.rel" contains the unpacked distribution. "mgr.new" contains the distribution with fixes. The following was created with the two commands: touch mgr.rel/PATCH_1 mgr.rel/misc/{login,cshrc} diff -r -c mgr.rel mgr.new ---------------------------- cut here ------------------------------------ diff -r -c mgr.rel/PATCH_1 mgr.new/PATCH_1 *** mgr.rel/PATCH_1 Fri Jan 27 10:46:00 1989 --- mgr.new/PATCH_1 Fri Jan 27 09:56:00 1989 *************** *** 0 **** --- 1,12 ---- + Bugs found in the distribution + 1) MGR crashes on startup on SUNOS-4.0 + - fixed src/blit/bitmap.c + 2) src/kbd.c uses wrong include file for SUNOS-4.0 + - fixed include + - fixed missing #else for no -DKBD option + 3) user manual doesn't make + - fixed doc/usrman/Makefile + 4) Wrong heading on font(5) man page + - fixed doc/font.5 + 5) The files misc/mgrc and misc/login are missing + - they've been added. diff -r -c mgr.rel/doc/font.5 mgr.new/doc/font.5 *** mgr.rel/doc/font.5 Tue Jan 24 15:56:39 1989 --- mgr.new/doc/font.5 Fri Jan 27 08:55:01 1989 *************** *** 7,13 **** '\" '\" $Header: font.5,v 4.1 88/06/21 13:51:34 bianchi Exp $ '\" $Source: /tmp/mgrsrc/doc/RCS/font.5,v $ ! .TH bitmap 5L "April 30, 1986" .SH NAME Font \- font file format for .I mgr --- 7,13 ---- '\" '\" $Header: font.5,v 4.1 88/06/21 13:51:34 bianchi Exp $ '\" $Source: /tmp/mgrsrc/doc/RCS/font.5,v $ ! .TH font 5L "April 30, 1986" .SH NAME Font \- font file format for .I mgr diff -r -c mgr.rel/doc/usrman/Makefile mgr.new/doc/usrman/Makefile *** mgr.rel/doc/usrman/Makefile Tue Jan 24 15:57:31 1989 --- mgr.new/doc/usrman/Makefile Thu Jan 26 09:43:27 1989 *************** *** 11,17 **** # manual makefile ! PARTS= doc.0 doc.1 doc.2 doc.3 doc.4 doc.5 doc.6 doc.7 doc.8 doc.9 EXTRACT= doc.0 doc.1 doc.2 doc.3 doc.4 doc.5 doc.6 # croff (c-source => troff input converter) flags --- 11,17 ---- # manual makefile ! PARTS= doc.0 doc.1 doc.2 doc.3 doc.4 doc.5 doc.6 doc.7 doc.8 EXTRACT= doc.0 doc.1 doc.2 doc.3 doc.4 doc.5 doc.6 # croff (c-source => troff input converter) flags *************** *** 80,91 **** nroff: $(MAKE) TROFF=nroff PRINT=nroff PRINTER=$(PRINTER) all ! install: $(INSDIR) -rm -f $(INSDIR)/$(NAME) ! cp $(NAME) $(INSDIR)/$(NAME) $(INSDIR): ! mkdir $@ clean: rm -f temp --- 80,97 ---- nroff: $(MAKE) TROFF=nroff PRINT=nroff PRINTER=$(PRINTER) all ! install: $(INSDIR) $(NAME) -rm -f $(INSDIR)/$(NAME) ! -cp $(NAME) $(INSDIR)/$(NAME) $(INSDIR): ! -mkdir $@ ! ! $(NAME): $(CROFF) ! $(MAKE) -s PRINTER=crt nroff > $(NAME) ! ! $(CROFF): ! cd croff;$(MAKE) croff clean clean: rm -f temp diff -r -c mgr.rel/misc/README mgr.new/misc/README *** mgr.rel/misc/README Tue Jan 24 15:56:32 1989 --- mgr.new/misc/README Fri Jan 27 09:48:36 1989 *************** *** 20,26 **** mgr.ti A sample MGR terminfo entry ! mgrc some sample MGR startup files ans notes plot PLot(5) format data try mgrplot < plot --- 20,26 ---- mgr.ti A sample MGR terminfo entry ! mgrc some sample MGR startup files and notes plot PLot(5) format data try mgrplot < plot diff -r -c mgr.rel/misc/login mgr.new/misc/login *** mgr.rel/misc/login Fri Jan 27 10:58:09 1989 --- mgr.new/misc/login Fri Jan 27 09:51:45 1989 *************** *** 0 **** --- 1,39 ---- + ------------------------------------------------------------------- + This is a typical MGR compatable .login file, demonstrating the method for + starting commands remotely in your .mgrc. To start the command "FOO" + on host "bar" use a line in .mgrc such as: + "start setenv TERM FOO.mgr;rlogin bar\r" + and this .login on host "bar". + + set noglob + stty new dec erase crt ctlecho + setenv HOST `hostname` + setenv EDITOR vi + setenv PRINTER lj + setenv MANPATH "/usr/mgr/man:/usr/sau/man:/usr/local/man:/usr/man" + set prompt="$HOST% " + switch($term) + case su: + case net: + case switch: + case unknown: + eval `tset -s -n -Q -m :?wy` + breaksw + case sun: + echo "[p" + setenv MORE "-cs" + caps n + swap_kbd + breaksw + case mgr: + eval `set_termcap` + setenv MORE "-cs" + breaksw + case *.mgr: + setenv TERM mgr + eval `set_termcap` + setenv MORE "-cs" + exec `basename $term .mgr` + breaksw + endsw + unset noglob diff -r -c mgr.rel/misc/mgrc mgr.new/misc/mgrc *** mgr.rel/misc/mgrc Fri Jan 27 10:58:09 1989 --- mgr.new/misc/mgrc Fri Jan 27 09:52:30 1989 *************** *** 0 **** --- 1,108 ---- + Here are 3 sample .mgrc files, borrowed from random local MGR usrs (the + files are indented for clarity only). Lines staring at the left margin + are comments and not part of the files. + ------------------------------------------------------------------- + font 8 gal8x16r.fnt + font 9 gal8x16b.fnt + font 10 gal8x16ru.fnt + font 11 gal12x20r.fnt + font 12 gal12x20b.fnt + font 13 gal12x20ru.fnt + font 14 gal12x20bu.fnt + These two entries control the default behavior of paging and sliding menus + slide 50 8 + page 8 25 + window 29 93 971 708 12 + start sleep 6;echo -n "\e8S";set_console\r + This next window is used to track mail delivery. .mailrc contains + sendmail=Sendmail and Sendmail is the shell script: "sendmail -v $* >> + $HOME/.sm" + window 29 806 491 90 1 + start echo \f-Mail Delivery Status- > ~/.sm;tail -f ~/.sm\r + window 2 2 72 72 + shell nice clock2 -c + window 76 2 72 72 + shell iconmail -s + window 150 2 72 72 + shell iconmsgs -s + window 228 2 72 72 + shell nice walk + window 304 2 464 72 1 + shell nice stat -10 d1 us -5 r + window 775 2 380 72 1 + shell nice ether + window 406 326 730 556 6 + shell -ksh + window 1008 81 46 46 1 + start cut -s\r + window 1068 81 76 74 1 + start echo 6h;setenv PRINTER lj;snap ~/snap\r + done + ------------------------------------------------------------------- + Sample .mgrc # 2. + font 1 sail6x8r.fnt + font 2 80x2.fnt + font 3 81.fnt + font 4 shad_16.fnt + window 0 80 570 810 2 + start rlogin gobo -8\r + window 576 80 570 810 2 + start rlogin gobo -8\r + window 0 480 570 394 2 + start rlogin gobo -8\r + window 576 480 570 394 2 + start rlogin gobo -8\r + window 8 92 1130 760 3 + start ta\r + window 440 4 72 72 + shell iconmail -s + window 516 4 72 72 + shell iconmsgs -s + window 0 4 216 72 4 + shell clock -s + done + ------------------------------------------------------------------- + This .mgrc was setup for a Sun 3-110/c (color) + initcmd set_colormap + resumecmd overlay + font 16 80x2.fnt + font 17 upside8x12.fnt + + window -1 -1 -1 -1 11 + newwindow + + window 0 0 74 74 + start flashloop iconmail\r + + window 74 0 74 74 + start flashloop iconmsgs\r + + window 148 0 74 74 + shell clock -b + windowsetid 11 + + window -1 -1 80c 80c 11 + start flashloop\r + active + + window -1 -1 80c 80c 11 + start sleep 2;iconifycmd -n heavy $SHELL\r + + window -1 -1 80c 80c 0 + start sleep 4;iconifycmd flash\r + windowsetid 7 + + window 502 80 650 394 0 + start sleep 6;iconifycmd -n dq... dq\r + windowsetid 8 + + window 422 145 730 442 7 + start sleep 8;iconifycmd -n micom eval SHELL=micom hpmgr\r + windowsetid 9 + + window 0 250 490 650 1 + start set_console\r + windowsetid 10 + + done + ------------------------------------------------------------------- Only in mgr.new/src: icons.h diff -r -c mgr.rel/src/kbd.c mgr.new/src/kbd.c *** mgr.rel/src/kbd.c Tue Jan 24 15:58:35 1989 --- mgr.new/src/kbd.c Fri Jan 27 10:43:21 1989 *************** *** 20,26 **** # include <sys/types.h> # include <sundev/kbio.h> # ifndef TIOCCONS /* definiton moved in rel. 4.0 */ ! # include "<sys/termios.h>" # endif #endif KBD #endif --- 20,26 ---- # include <sys/types.h> # include <sundev/kbio.h> # ifndef TIOCCONS /* definiton moved in rel. 4.0 */ ! # include <sys/ttycom.h> /* was sys/termios.h */ # endif #endif KBD #endif *************** *** 108,115 **** setitimer(ITIMER_REAL,&new,&old); } #endif - static int kbd_fd = -1; --- 108,117 ---- setitimer(ITIMER_REAL,&new,&old); } + #else + int + kbd_reset() {} #endif static int kbd_fd = -1; diff -r -c mgr.rel/src/blit/bitmap.c mgr.new/src/blit/bitmap.c *** mgr.rel/src/blit/bitmap.c Tue Jan 24 15:58:48 1989 --- mgr.new/src/blit/bitmap.c Fri Jan 27 10:32:40 1989 *************** *** 66,72 **** #ifdef _MAP_NEW /* New semantics for mmap in Sun release 4.0 */ addr = (DATA) mmap(addr, _s_len=buff.fb_size, ! PROT_WRITE, _MAP_NEW|MAP_SHARED, fd, 0); if ((int)addr == -1) return (BIT_NULL); #else --- 66,72 ---- #ifdef _MAP_NEW /* New semantics for mmap in Sun release 4.0 */ addr = (DATA) mmap(addr, _s_len=buff.fb_size, ! PROT_READ|PROT_WRITE, _MAP_NEW|MAP_SHARED, fd, 0); if ((int)addr == -1) return (BIT_NULL); #else diff -r -c mgr.rel/src/oblit/bitmap.c mgr.new/src/oblit/bitmap.c *** mgr.rel/src/oblit/bitmap.c Tue Jan 24 15:58:51 1989 --- mgr.new/src/oblit/bitmap.c Fri Jan 27 10:33:01 1989 *************** *** 66,72 **** #ifdef _MAP_NEW /* New semantics for mmap in Sun release 4.0 */ addr = (DATA) mmap(addr, _s_len=buff.fb_size, ! PROT_WRITE, _MAP_NEW|MAP_SHARED, fd, 0); if ((int)addr == -1) return (BIT_NULL); #else --- 66,72 ---- #ifdef _MAP_NEW /* New semantics for mmap in Sun release 4.0 */ addr = (DATA) mmap(addr, _s_len=buff.fb_size, ! PROT_READ|PROT_WRITE, _MAP_NEW|MAP_SHARED, fd, 0); if ((int)addr == -1) return (BIT_NULL); #else -- Please send comp.sources.unix-related mail to rsalz@uunet.uu.net.