Thread View: net.bugs
1 messages
1 total messages
Started by Gene Spafford
Fri, 03 Oct 1986 16:00
PMDF vs. 4.3BSD
Author: Gene Spafford
Date: Fri, 03 Oct 1986 16:00
Date: Fri, 03 Oct 1986 16:00
87 lines
2640 bytes
2640 bytes
If any of you are running PMDF II (as many CSNet sites are), you will
discover that PMDF will not work once you convert to 4.3BSD. It works
a little, but keeps timing out and your queue keeps growing.
Well, after a few dead-ends, we found the problem. The following
changes should be made to your PMDF code and then the whole
package should be recompiled and relinked.
Mark Johnson
Gene Spafford
postmasters at GaTech
*** osc.c.orig Wed Oct 1 10:41:55 1986
--- osc.c Wed Oct 1 10:59:44 1986
***************
*** 10,15 ****
--- 10,16 ----
#include <stdio.h>
#include <fcntl.h>
#include <sgtty.h>
+ #include <sys/types.h>
#include "pcvars.h" /* excerpt from h00vars.h */
#define R_OK 4
***************
*** 236,248 ****
register int r;
struct timeval timeout;
! int readfs;
timeout.tv_sec = timelimit;
timeout.tv_usec = 0;
! readfs = 1;
! select(1,&readfs,0,0,&timeout);
! if (readfs == 0) return(0);
r = read(fileno(stdin),ch,1);
(*ch) &= 0x7f;
if (r < 0) return(-errno);
--- 237,251 ----
register int r;
struct timeval timeout;
! int s_result;
! fd_set readfs;
timeout.tv_sec = timelimit;
timeout.tv_usec = 0;
! FD_ZERO(&readfs);
! FD_SET(0, &readfs);
! s_result = select(1,&readfs,0,0,&timeout);
! if (s_result <= 0 || !FD_ISSET(0, &readfs)) return(0);
r = read(fileno(stdin),ch,1);
(*ch) &= 0x7f;
if (r < 0) return(-errno);
***************
*** 257,269 ****
{
struct timeval timeout;
! int readfs;
timeout.tv_sec = timelimit;
timeout.tv_usec = 0;
! readfs = 1;
! select(1,&readfs,0,0,&timeout);
! if (readfs == 0) return(0);
gets(packet->body, sizeof packet->body);
if ferror(stdin) {
clearerr(stdin);
--- 260,274 ----
{
struct timeval timeout;
! int s_result;
! fd_set readfs;
timeout.tv_sec = timelimit;
timeout.tv_usec = 0;
! FD_ZERO(&readfs);
! FD_SET(0, &readfs);
! s_result = select(1,&readfs,0,0,&timeout);
! if (s_result <= 0 || !FD_ISSET(0, &readfs)) return(0);
gets(packet->body, sizeof packet->body);
if ferror(stdin) {
clearerr(stdin);
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads