🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sources.bugs
Article #538

Patch #2 to Pcomm v2.0

#538
From: Emmet P. Gray
Date: Fri, 06 Nov 1992 14:34
296 lines
8731 bytes
This is patch #2 to the Pcomm v2.0 distribution package.  Pcomm is a
public domain, menu driven, telecommunication program for Unix designed
to operate similarily to the popular MSDOS program, ProComm.

This patch will fix a few problems with possible loss of the inherited
environment for child processes, and a bug in the data and print logging
when used during scripts.

Emmet P. Gray				US Army, HQ III Corps & Fort Hood
...!uunet!uiucuxc!fthood!egray		Attn: AFZF-DE-ENV
fthood!egray@uxc.cso.uiuc.edu		Directorate of Engineering & Housing
					Environmental Management Office
					Fort Hood, TX 76544-5057

-------------------------------------------------------------------------------
Prereq: "2.0.1"
*** old/patchlevel.h	Sun Sep  6 16:06:50 1992
--- patchlevel.h	Thu Nov  5 08:07:18 1992
***************
*** 1,2 ****
! #define VERSION "2.0.1"
! #define DATE "6 Sep 92"
--- 1,2 ----
! #define VERSION "2.0.2"
! #define DATE "6 Nov 92"
*** old/Configure.sh	Sun Sep  6 16:06:45 1992
--- Configure.sh	Fri Oct  2 07:35:57 1992
***************
*** 16,27 ****
  if [ -d /usr/spool/locks ] ;then
  	echo "Your UUCP lock files go in /usr/spool/locks"
! 	echo "Therefore you need:	#define LOCK_FILE \"/usr/spool/locks\""
  else
  	if [ -d /usr/spool/uucp/LCK ]; then
  		echo "Your UUCP lock files go in /usr/spool/uucp/LCK"
! 		echo "Therefore you need:	#define LOCK_FILE \"/usr/spool/uucp/LCK\""
  	else
  		echo "Your UUCP lock files go in /usr/spool/uucp"
! 		echo "Therefore you need:	#define LOCK_FILE \"/usr/spool/uucp\""
  	fi
  fi
--- 16,27 ----
  if [ -d /usr/spool/locks ] ;then
  	echo "Your UUCP lock files go in /usr/spool/locks"
! 	echo "Therefore you need:	#define LOCK_DIR \"/usr/spool/locks\""
  else
  	if [ -d /usr/spool/uucp/LCK ]; then
  		echo "Your UUCP lock files go in /usr/spool/uucp/LCK"
! 		echo "Therefore you need:	#define LOCK_DIR \"/usr/spool/uucp/LCK\""
  	else
  		echo "Your UUCP lock files go in /usr/spool/uucp"
! 		echo "Therefore you need:	#define LOCK_DIR \"/usr/spool/uucp\""
  	fi
  fi
*** old/Release.notes	Sun Sep  6 16:06:47 1992
--- Release.notes	Thu Nov  5 08:25:32 1992
***************
*** 1,2 ****
--- 1,9 ----
+ Patch #2, 6 Nov 92
+ 
+ This patch will fix a few problems with possible loss of the inherited
+ environment for child processes, and a bug in the data and print logging
+ when used during scripts.
+ 
+ -----------------------------------------------------------------------------
  Patch #1, 6 Sep 92
  
*** old/Unixpc.shar	Sun Sep  6 16:06:47 1992
--- Unixpc.shar	Fri Oct  2 07:52:11 1992
***************
*** 9,15 ****
  #	Setup.sh
  #	config.h
! # This archive created: Fri Jul 17 13:45:30 1992
  export PATH; PATH=/bin:/usr/bin:$PATH
! echo shar: "extracting 'Makefile'" '(6623 characters)'
  if test -f 'Makefile'
  then
--- 9,15 ----
  #	Setup.sh
  #	config.h
! # This archive created: Sun Sep  6 13:04:17 1992
  export PATH; PATH=/bin:/usr/bin:$PATH
! echo shar: "extracting 'Makefile'" '(6665 characters)'
  if test -f 'Makefile'
  then
***************
*** 39,42 ****
--- 39,46 ----
  X#LD = /usr/5bin/cc
  X
+ X#for SVR3.2
+ X#SHLIB = -lc_s
+ X#OTHER = -lpt
+ X
  X#LD = cc
  X#SHLIB =
***************
*** 223,229 ****
  Xwaitfor.o:	config.h
  SHAR_EOF
! if test 6623 -ne "`wc -c < 'Makefile'`"
  then
! 	echo shar: "error transmitting 'Makefile'" '(should have been 6623 characters)'
  fi
  fi
--- 227,233 ----
  Xwaitfor.o:	config.h
  SHAR_EOF
! if test 6665 -ne "`wc -c < 'Makefile'`"
  then
! 	echo shar: "error transmitting 'Makefile'" '(should have been 6665 characters)'
  fi
  fi
***************
*** 504,508 ****
  fi
  fi
! echo shar: "extracting 'config.h'" '(2446 characters)'
  if test -f 'config.h'
  then
--- 508,512 ----
  fi
  fi
! echo shar: "extracting 'config.h'" '(2524 characters)'
  if test -f 'config.h'
  then
***************
*** 592,595 ****
--- 596,602 ----
  X#undef	HAVE_USLEEP
  X
+ X/* Does your system have the truncate() system call? */
+ X#undef	HAVE_TRUNCATE
+ X
  X/* typedef void SIG_TYPE; */
  Xtypedef int SIG_TYPE;
***************
*** 600,606 ****
  X#endif /* BSD */
  SHAR_EOF
! if test 2446 -ne "`wc -c < 'config.h'`"
  then
! 	echo shar: "error transmitting 'config.h'" '(should have been 2446 characters)'
  fi
  fi
--- 607,613 ----
  X#endif /* BSD */
  SHAR_EOF
! if test 2524 -ne "`wc -c < 'config.h'`"
  then
! 	echo shar: "error transmitting 'config.h'" '(should have been 2524 characters)'
  fi
  fi
*** old/cmd.c	Sun Sep  6 16:06:47 1992
--- cmd.c	Thu Nov  5 10:49:19 1992
***************
*** 25,29 ****
  	char buf[256], *s, arg2[256], *strchr(), *str_rep();
  	char *entry, *strtok(), ld_code;
! 	void hang_up(), line_set(), pexit(), screen_dump();
  
  	if (ipc_read(status->cmd_ipc, buf, 256))
--- 25,30 ----
  	char buf[256], *s, arg2[256], *strchr(), *str_rep();
  	char *entry, *strtok(), ld_code;
! 	void hang_up(), line_set(), pexit(), screen_dump(), log_toggle();
! 	void lpr_toggle();
  
  	if (ipc_read(status->cmd_ipc, buf, 256))
***************
*** 226,230 ****
  			break;
  		case PRINTER:
! 			status->print_status = arg1;
  			break;
  		case MODEM_BREAK:
--- 227,232 ----
  			break;
  		case PRINTER:
! 			if (status->print_status + arg1 == 1)
! 				lpr_toggle();
  			break;
  		case MODEM_BREAK:
***************
*** 241,245 ****
  			break;
  		case DATA_LOG:
! 			status->log_status = arg1;
  			break;
  		default:
--- 243,251 ----
  			break;
  		case DATA_LOG:
! 			if (status->log_status + arg1 == 1) {
! 				if (arg1 == 1 && !strcmp(status->log_path, "NOT_DEFINED"))
! 					status->log_path = str_rep(status->log_path, param->logfile);
! 				log_toggle();
! 			}
  			break;
  		default:
*** old/pcomm_cmd.c	Sun Sep  6 16:06:50 1992
--- pcomm_cmd.c	Wed Nov  4 08:40:37 1992
***************
*** 33,37 ****
  	static char *xfer_args[] = {"XMODEM", "XMODEM_1K", "MODEM7", "YMODEM",
  	"YMODEM_G", "ASCII", "EXT_1", "EXT_2", "EXT_3", 0};
! 	char *command, buf[40], *mkupper(), *arg1, *arg2, *s, *strchr();
  	char *pcomm_cmd, *getenv();
  	int cmd_num, i, arg_num, got_it;
--- 33,37 ----
  	static char *xfer_args[] = {"XMODEM", "XMODEM_1K", "MODEM7", "YMODEM",
  	"YMODEM_G", "ASCII", "EXT_1", "EXT_2", "EXT_3", 0};
! 	char *command, buf[256], *mkupper(), *arg1, *arg2, *s, *strchr();
  	char *pcomm_cmd, *getenv();
  	int cmd_num, i, arg_num, got_it;
*** old/s_prompt.c	Sun Sep  6 16:06:51 1992
--- s_prompt.c	Thu Nov  5 08:00:53 1992
***************
*** 28,32 ****
  	wrefresh(win);
  
! 	if ((ans = get_str(win, 80, "", "\n")) == NULL)
  		return(NULL);
  					/* check the value */
--- 28,32 ----
  	wrefresh(win);
  
! 	if ((ans = get_str(win, 80, "", ";\n")) == NULL)
  		return(NULL);
  					/* check the value */
*** old/script.c	Sun Sep  6 16:06:52 1992
--- script.c	Fri Oct  2 07:46:44 1992
***************
*** 258,285 ****
  	int n;
  	extern char **environ;
! 	char **envp, buf[80], **temp, *malloc(), *str_dup();
  
  					/* how many variables do we have? */
! 	temp = environ;
  	n = 0;
! 	while (*temp != NULL) {
  		n++;
! 		temp++;
  	}
  
  	envp = (char **) malloc((n+2) * sizeof(char *));
! 	temp = envp;
! 	while (*environ != NULL) {
  					/* don't copy an old value */
! 		if (strncmp(*environ, "PCOMM_CMD=", 10)) {
! 			*temp = str_dup(*environ);
! 			temp++;
  		}
! 		environ++;
  	}
  	sprintf(buf, "PCOMM_CMD=%s", key);
! 	*temp = str_dup(buf);
! 	temp++;
! 	*temp = NULL;
  	return(envp);
  }
--- 258,286 ----
  	int n;
  	extern char **environ;
! 	char **envp, buf[80], **old, **new, *malloc(), *str_dup();
  
  					/* how many variables do we have? */
! 	old = environ;
  	n = 0;
! 	while (*old != NULL) {
  		n++;
! 		old++;
  	}
  
  	envp = (char **) malloc((n+2) * sizeof(char *));
! 	new = envp;
! 	old = environ;
! 	while (*old != NULL) {
  					/* don't copy an old value */
! 		if (strncmp(*old, "PCOMM_CMD=", 10)) {
! 			*new = str_dup(*old);
! 			new++;
  		}
! 		old++;
  	}
  	sprintf(buf, "PCOMM_CMD=%s", key);
! 	*new = str_dup(buf);
! 	new++;
! 	*new = NULL;
  	return(envp);
  }
End of Patch
Technical Details
Message-ID: <BxAtsx.JuE@news.cso.uiuc.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!uwm.edu!ux1.cso.uiuc.edu!news.cso.uiuc.edu!osiris.cso.uiuc.edu!egray

Show Full Headers
Complete Article Headers
Newsgroups: comp.sources.bugs
Path: arc1-ca.pugleaf.net!sparky!uunet!zaphod.mps.ohio-state.edu!uwm.edu!ux1.cso.uiuc.edu!news.cso.uiuc.edu!osiris.cso.uiuc.edu!egray
From: egray@osiris.cso.uiuc.edu (Emmet P. Gray)
Subject: Patch #2 to Pcomm v2.0
Message-ID: <BxAtsx.JuE@news.cso.uiuc.edu>
Sender: usenet@news.cso.uiuc.edu (Net Noise owner)
Organization: US Army Corps of Engineers - Construction Eng Research Lab
Date: Fri, 6 Nov 1992 14:34:07 GMT
Lines: 296