/* routine to do PL/I-style string assignment to a PL/I string, given descriptor pointer, and pointer & byte count of new value. returns true if string didn't fit (does not raise STRINGSIZE condition). */ #include ; #include ; boolean function plicpy(sdp,ps,nbytes) plistring sdp; char *ps[]; int nbytes; { int nb; register int ssize, i; register char *dstp, *srcp; boolean oflo; ssize = sdp plisize; /*how much space available*/ iff oflo = ( (nb=nbytes) > ssize ) then nb=ssize; /*truncate if necessary*/ srcp = ps; dstp = plistr(sdp); for (i=0; iplisdptr.plisdvsp)->plivslen = nb; /*varying - set new length*/ else while (i