Post by JShepherdOn Monday, May 31, 2021 at 3:59:31 PM UTC-4, Bill Honaker wrote:=20
com> wrote:=20
sala:=20
On Friday, May 28, 2021 at 12:49:03 PM UTC-7, Bill Honaker wrote:=
=20
mail.com> wrote:=20
=20
Hi,=20
I'm writing C program that would get the status of the xpnet ob=
jects (stations,processes,node...). I'm using procedures described in the H=
P manuals(Pathsend and Server programming Manual, C/C++ programmer's Guide.=
..) but I can't get anyting from Pathway except errors. Can you tell me wha=
t am I doing wrong?=20
=20
This is the code that I'm working on:=20
---------------------------------------------------------------=
-------------------------------------------------=20
include <stdlib.h>=20
#include <stdio.h>=20
#include <string.h>=20
#include <cextdecs (SERVERCLASS_SEND_, SERVERCLASS_SEND_INFO_)>=
nolist=20
#include <tal.h>=20
=20
main()=20
{=20
short error, error2,pserror, fserror,countread;=20
char *pmon;=20
char *buffer;=20
char *sname;=20
=20
pmon =3D"$D1MN";=20
sname =3D "SERVER-NCPI-1A";=20
buffer =3D"STATUS PROCESS P1A^BICUNI1";=20
=20
error =3D SERVERCLASS_SEND_ (pmon,=20
(short) strlen(pmon), /* pathmon */=20
sname,=20
(short) strlen(sname), /* server class */=20
buffer,=20
(short) strlen(buffer),=20
200,=20
&countread,=20
-1); /* timeout =3D forever */=20
=20
if (error !=3D 0)=20
{=20
error2 =3D SERVERCLASS_SEND_INFO_ (&pserror, &fserror);=20
printf ("\nSERVERCLASS_SEND_ error =3D %d, pathsend error =3D =
%d, fs error =3D %d\n", error, pserror, fserror);=20
exit (1);=20
}=20
else=20
{=20
buffer [countread] =3D 0;=20
printf ("\nReply =3D %s\n", buffer);=20
}=20
}=20
---------------------------------------------------------------=
-------------------------------------------------=20
Response:=20
SERVERCLASS_SEND_ error =3D 233, pathsend error =3D 904, fs err=
or =3D 12=20
=20
Best Regards,=20
Uros=20
Uros,=20
=20
Keith and Randall gave very valuable responses.=20
=20
Also one other possibility is that, in creating the link, the PA=
THMON tried to start a server process.=20
If that server process has a fixed PROCESS NAME for each isntanc=
e, and if there is already a running process with that name,=20
the attempt to start the process would get an error 12. Look at =
the info ("PATHCOM $D1MN;INFO SERVER-NCPI-1A") and=20
check what is in the "PROCESS". If it's present, there will eith=
er be one process name, or a list in paraentheses.=20
From a TACL prompt, issue a status command for each process in t=
he list.=20
=20
Bill=20
Bill,=20
=20
Very good remembering that filesystem error 12 is used for attempt=
ing to start a process with a name that already exists. I should have remem=
bered that myself. Unless Pathway's link management also uses filesystem er=
ror 12 for other problems, I'd say a duplicate process name is likely to be=
the explanation for this problem. Perhaps Uros has set up a test environme=
nt by duplicating the configuration of an existing environment and did not =
know to change the configured fixed server process names.=20
Hi,=20
=20
Thank you all for your help.=20
=20
I changed the code:=20
1) I added SERVERCLASS_SEND_INFO output error number to see if comma=
nd was succsesfully processed.=20
2) I changed the buffer to a 200-byte array.=20
3) I find some tal example of a similar program and I noticed that t=
his tal program, sends the command to a different pathway server. I send it=
to the SERVER-NCPI-1A server, which is a server for P1A^NODE. But the tal =
program sends the command to the server SERVER-NCP, which sees all "node" s=
ervers.=20
=20
It is interesting because if I send a command to SERVER-NCP I get a =
different error code.=20
SERVER-NCP:=20
SERVERCLASS_SEND_ error =3D 233, pathsend error =3D 904, fs error =
=3D 21=20
=20
SERVER-NCP-1A:=20
SERVERCLASS_SEND_ error =3D 233, pathsend error =3D 904, fs error =
=3D 12=20
=20
I think that the correct server is a SERVER-NCP.=20
=20
--------------------------------------------------------------------=
-------------------------------------------------------------------------=
=20
Pahway server configuration:=20
MAXLINKMONS 20 [CURRENTLY 2]=20
=20
SERVER SERVER-NCPI-1A=20
LINKDEPTH 1=20
MAXLINKS 32=20
MAXSERVERS 3=20
PROCESS $D1AU (ASSOCIATIVE ON)=20
=20
SERVER SERVER-NCP=20
LINKDEPTH 32=20
MAXLINKS 32=20
MAXSERVERS 3=20
PROCESS $D1C1=20
PROCESS $D1C2=20
PROCESS $D1C3=20
--------------------------------------------------------------------=
-------------------------------------------------------------------------=
=20
code:=20
#include <stdlib.h>=20
#include <stdio.h>=20
#include <string.h>=20
#include <tal.h>=20
#include <cextdecs (SERVERCLASS_SEND_, SERVERCLASS_SEND_INFO_)> noli=
st=20
main()=20
{=20
short error, error2, pserror, fserror,countread;=20
char *pmon;=20
char buffer [200]=3D{0};=20
char *sname;=20
=20
pmon =3D"$D1MN";=20
sname =3D "SERVER-NCP";=20
strcpy(buffer,"STATUS PROCESS P1A^BICUNI1");=20
=20
error =3D SERVERCLASS_SEND_ (pmon,=20
(short)strlen(pmon), /* pathmon */=20
sname,=20
(short)strlen(sname), /* server class */=20
buffer,=20
(short)strlen(buffer),=20
200,=20
&countread,=20
-1); /* timeout =3D forever */=20
if (error !=3D 0)=20
{=20
error2 =3D SERVERCLASS_SEND_INFO_ (&pserror, &fserror);=20
printf("\nSERVERCLASS_SEND_INFO error =3D %d \nSERVERCLASS_SEND_ er=
ror =3D %d, pathsend error =3D %d, fs error =3D %d\n",error2, error, pserro=
r, fserror);=20
printf("\nBuffer size =3D %d\n", strlen(buffer));=20
=20
int i;=20
for(i=3D0; i<strlen(buffer); i++)=20
{=20
printf("%c",buffer[i]);=20
}=20
printf("\n\n\n");=20
exit (1);=20
}=20
else=20
{=20
buffer [countread] =3D 0;=20
printf ("\nReply =3D %s\n", buffer);=20
}=20
}=20
I see the original server was setup with 'Asoociative On' It's possib=
le the open table in the server can't accept another open.=20
=20
Can't explain the error 21.=20
I would try changing PMON and SNAME from pointers to arrays and see if =
it doesn't help with the error 21.=20
char pmon[] =3D "$D1MN";
char sname[] =3D "SERVER-NCP";=20
=20
Dave
Hi,=20
=20
Keith, I don't find anything in the manuals, that would show me what to s=
end to the server.=20
=20
I did not post the complete output to make this thread readable as possib=
le. The SERVERCLASS_SEND_INFO returns 0(OK) and I tried different data type=
s, also arrays instead of pointers. The result is the same. I'm almost sure=
that I need to send command to the SERVER-NCP server instead the SERVER-NC=
PI-1A.=20
=20
Currently I'm using arrays:=20
=20
char pmon[5]=3D{0};
char buffer [200]=3D{0};
char sname[20]=3D{0};=20
=20
strcpy(pmon,"$D1MN");=20
strcpy(sname,"SERVER-NCP");
strcpy(buffer,"STATUS PROCESS P1A^BICUNI1");=20
=20
error =3D SERVERCLASS_SEND_ (pmon,=20
(short)strlen(pmon), /* pathmon */=20
sname,=20
(short)strlen(sname), /* server class */=20
buffer,=20
(short)strlen(buffer),=20
200,=20
&countread,=20
-1); /* timeout =3D forever */
OUTPUT:=20
SERVERCLASS_SEND_INFO error =3D 0
SERVERCLASS_SEND_ error =3D 233, pathsend error =3D 904, fs error =3D 21
Buffer size =3D 26=20
STATUS PROCESS P1A^BICUNI1=20
=20
=20
EMS messages:=20
=20
21-06-02;10:03:23.101 \PERUN.$D1MN TANDEM.PATHWAY.L01 3116=20
\PERUN.$D1MN: ERROR - *3116* LINKMON L\PERUN.$ZP01,=20
ERROR DURING SERVER I/O (21) - SERVER SERVER-NCP=20
=20
21-06-02;10:03:23.102 \PERUN.$D1SUD TANDEM.VHS.L01 6=20
DEV1VHS:=20
02JUN21,10:03 $D1MN: ERROR - *3116* LINKMON L\PERUN.$ZP01, ERROR=20
DURING SERVER I/O (21) - SERVER SERVER-NCP. Display text received=20
from process $D1MN. Program file \PERUN.$SYSTEM.SYSTEM.PATHMON.=20
Primary log file \PERUN.$DATA01.DEV1VHS.LOG0000.=20
=20
I'm losing ideas what else to try.=20
=20
Uros
I just notice another EMS error in collector $0
21-06-02;11:39:59.662 \PERUN.$ZL01 TANDEM.APPCLSTR.L01 1038
WARNING 1038 - Server \PERUN.$D1MN.SERVER-NCP file
operation ACS_FS_PSWRITEREAD_() failed, process
\PERUN.$D1C1:115841149, file \PERUN.$D1C1, error 21
Uros
Are you sure that server accepts a command line text buffer as input ?
Maybe it requires a structured message.
=status SERVER-NCPI-1A
SERVER-NCPI-1A 1
PROCESS STATE ERROR INFO #LINKS WEIGHT
$S1AU RUNNING 1 3
10> wake /highpin off/ $s1au
WRITE error 21 on $S1AU
11> wake /highpin off/ $s1au send STATUS
WRITE error 21 on $S1AU
Hi,
I'm still trying to understand why my code doesn't work. I think that something is wrong with the structures.
This tal program was written by my coworker.
?symbols !NCPSTASTAT
?inspect !NCPSTASTAT
!NCPSTASTAT
?nolist, source $system.system.extdecs0( !NCPSTASTAT
? close, !NCPSTASTAT
? initializer, !NCPSTASTAT
? myterm, !NCPSTASTAT
? numout, !NCPSTASTAT
? open, !NCPSTASTAT
? time, !NCPSTASTAT
? serverclass_send_, !NCPSTASTAT
? serverclass_send_info_, !NCPSTASTAT
? shiftstring, !NCPSTASTAT
? write ) !NCPSTASTAT
!NCPSTASTAT
?nolist, source $data02.aciutils.sysmsgs( !NCPSTASTAT
? ci^startup ) !NCPSTASTAT
!NCPSTASTAT
?nolist, source $data02.ba60src.bancptal( !NCPSTASTAT
? attributes, !NCPSTASTAT
? constants, !NCPSTASTAT
? defs, !NCPSTASTAT
? ncp^lex^struct, !NCPSTASTAT
? errors^and^warnings, !NCPSTASTAT
? requests, !NCPSTASTAT
? responses, !NCPSTASTAT
? structs, !NCPSTASTAT
? token ) !NCPSTASTAT
!NCPSTASTAT
!NCPSTASTAT
! globals !!NCPSTASTAT
string .pmon^nam^g[0:14] := [$occurs( pmon^nam^g ) * [" "]], !NCPSTASTAT
.sta^nam^g[0:15] := [$occurs( sta^nam^g ) * [" "]]; !NCPSTASTAT
!NCPSTASTAT
!NCPSTASTAT
proc startupproc( rucb, passthru, !NCPSTASTAT
startupbuf, startup^len, !NCPSTASTAT
match ) variable; !NCPSTASTAT
int .rucb, !NCPSTASTAT
.passthru, !NCPSTASTAT
.startupbuf, !NCPSTASTAT
startup^len, !NCPSTASTAT
match; !NCPSTASTAT
!NCPSTASTAT
begin !NCPSTASTAT
!NCPSTASTAT
int .startups( ci^startup ) := @startupbuf; !NCPSTASTAT
!NCPSTASTAT
string .start^list[0:23] := [$occurs( start^list ) * [" "]], !NCPSTASTAT
.sptr, !NCPSTASTAT
.eptr; !NCPSTASTAT
!NCPSTASTAT
!NCPSTASTAT
! !!NCPSTASTAT
! Get argument parameters !!NCPSTASTAT
! !!NCPSTASTAT
if not startups.parm then !NCPSTASTAT
begin !NCPSTASTAT
! no arguments provided !!NCPSTASTAT
end !NCPSTASTAT
else !NCPSTASTAT
begin !NCPSTASTAT
! arguments provided, parse them !!NCPSTASTAT
start^list ':=' startups.parm for 12 words; !NCPSTASTAT
! all uppercase !!NCPSTASTAT
call shiftstring( start^list, $occurs( start^list ), 0 ); !NCPSTASTAT
!NCPSTASTAT
scan start^list until " " -> @sptr; !NCPSTASTAT
if not $carry then !NCPSTASTAT
begin !NCPSTASTAT
pmon^nam^g ':=' start^list for ( @sptr - @start^list ); !NCPSTASTAT
!NCPSTASTAT
scan sptr[1] until %h00 -> @eptr; !NCPSTASTAT
sta^nam^g ':=' sptr[1] for ( @eptr - @sptr[1] ); !NCPSTASTAT
end; !NCPSTASTAT
end; !NCPSTASTAT
!NCPSTASTAT
end; !NCPSTASTAT
!NCPSTASTAT
proc ncp^sta^stat main; !NCPSTASTAT
begin !NCPSTASTAT
!NCPSTASTAT
struct .ncp^rqst( ncp^lex^struct^def ); !NCPSTASTAT
!NCPSTASTAT
int .cnt^read := 0, !NCPSTASTAT
err := 0, !NCPSTASTAT
file^err := 0, !NCPSTASTAT
term^num := -1, !NCPSTASTAT
.ncp^resp( ncp^resp^struct^def ), !NCPSTASTAT
.ncp^resp^tkn( var^token^def ), !NCPSTASTAT
.ncp^resp^stat( ncp^resp^status^sta^def ), !NCPSTASTAT
.tim^array[0:6], !NCPSTASTAT
.term^name[0:11], !NCPSTASTAT
.buff[0:39]; !NCPSTASTAT
!NCPSTASTAT
string .srv^class[0:14] := ["SERVER-NCP "], !NCPSTASTAT
.cur^state[0:8], !NCPSTASTAT
.log^state[0:8], !NCPSTASTAT
.q^cnt[0:4], !NCPSTASTAT
.err^s[0:4], !NCPSTASTAT
.file^err^s[0:4]; !NCPSTASTAT
!NCPSTASTAT
!NCPSTASTAT
call initializer( ! rucb ! , !NCPSTASTAT
!passthru ! , !NCPSTASTAT
startupproc , !NCPSTASTAT
!paramproc ! , !NCPSTASTAT
!assignproc ! , !NCPSTASTAT
!flags! ); !NCPSTASTAT
!NCPSTASTAT
call myterm( term^name ); !NCPSTASTAT
! open hometerm !!NCPSTASTAT
call open( term^name, term^num ); !NCPSTASTAT
if <> then !NCPSTASTAT
begin !NCPSTASTAT
return; !NCPSTASTAT
end; !NCPSTASTAT
!NCPSTASTAT
! check if startup arguments were provided !!NCPSTASTAT
if pmon^nam^g = " " or !NCPSTASTAT
sta^nam^g = " " then !NCPSTASTAT
begin !NCPSTASTAT
buff ':=' "Provide PATHWAY PPD and STATION NAME arguments!"; !NCPSTASTAT
call write( term^num, buff, 47 ); !NCPSTASTAT
!NCPSTASTAT
call close( term^num ); !NCPSTASTAT
return; !NCPSTASTAT
end; !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.static.cmd := ncp^cmd^status; ! STATUS command !!NCPSTASTAT
ncp^rqst.static.obj^typ := ncp^obj^process; ! for STATIONS !!NCPSTASTAT
ncp^rqst.static.obj ':=' sta^nam^g for $occurs( sta^nam^g ); !NCPSTASTAT
ncp^rqst.static.rn ':=' [" "] & !NCPSTASTAT
ncp^rqst.static.rn for !NCPSTASTAT
$len( ncp^rqst.static.rn ) - 1; !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.static.end^user^id.user ':=' ! USERNAME !!NCPSTASTAT
[" "] & !NCPSTASTAT
ncp^rqst.static.end^user^id.user for !NCPSTASTAT
$len( ncp^rqst.static.end^user^id.user ) - 1; !NCPSTASTAT
ncp^rqst.static.user^info ':=' ! PASSWORD !!NCPSTASTAT
[" "] & !NCPSTASTAT
ncp^rqst.static.user^info for !NCPSTASTAT
$len( ncp^rqst.static.user^info ) - 1; !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.static.end^user^id.sess^id ':=' !NCPSTASTAT
[" "] & !NCPSTASTAT
ncp^rqst.static.end^user^id.sess^id for !NCPSTASTAT
$len( ncp^rqst.static.end^user^id.sess^id ) - 1; !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.static.cmd^timout := 1000d; !NCPSTASTAT
!NCPSTASTAT
call time( tim^array ); !NCPSTASTAT
! insert timestamp in NCP request structure !!NCPSTASTAT
call numout( ncp^rqst.static.tstamp.byte[0], !NCPSTASTAT
tim^array[0], 10, 2 ); !NCPSTASTAT
call numout( ncp^rqst.static.tstamp.byte[2], !NCPSTASTAT
tim^array[1], 10, 2 ); !NCPSTASTAT
call numout( ncp^rqst.static.tstamp.byte[4], !NCPSTASTAT
tim^array[2], 10, 2 ); !NCPSTASTAT
call numout( ncp^rqst.static.tstamp.byte[6], !NCPSTASTAT
tim^array[3], 10, 2 ); !NCPSTASTAT
call numout( ncp^rqst.static.tstamp.byte[8], !NCPSTASTAT
tim^array[4], 10, 2 ); !NCPSTASTAT
call numout( ncp^rqst.static.tstamp.byte[10], !NCPSTASTAT
tim^array[5], 10, 2 ); !NCPSTASTAT
call numout( ncp^rqst.static.tstamp.byte[12], !NCPSTASTAT
tim^array[6], 10, 2 ); !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.static.max^resps := ncp^val^max^resps^fill; !NCPSTASTAT
ncp^rqst.static.rqst^vsn ':=' ncp^val^version^300; !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.static.ctx^info ':=' !NCPSTASTAT
[" "] & !NCPSTASTAT
ncp^rqst.static.ctx^info for !NCPSTASTAT
$len( ncp^rqst.static.ctx^info ) - 1; !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.static.resp^typ := ncp^val^resp^err^warn^norm; !NCPSTASTAT
ncp^rqst.static.rqst^cntl := ncp^val^rqst^err^warn^norm; !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.dynamic^var1 ':=' !NCPSTASTAT
[%h00] & !NCPSTASTAT
ncp^rqst.dynamic^var1 for !NCPSTASTAT
$len( ncp^rqst.dynamic^var1 ) - 1; !NCPSTASTAT
!NCPSTASTAT
ncp^rqst.dynamic^area^lgth := $len( ncp^rqst.dynamic^area^lgth ); !NCPSTASTAT
! calculate NCP request length !!NCPSTASTAT
ncp^rqst.static.lgth := !NCPSTASTAT
$len( ncp^rqst.static ) + !NCPSTASTAT
$len( ncp^rqst.dynamic^area^lgth ) + !NCPSTASTAT
ncp^rqst.dynamic^area^lgth; !NCPSTASTAT
!NCPSTASTAT
! PATHSEND to SERVER-NCP !!NCPSTASTAT
err := serverclass_send_( pmon^nam^g, !NCPSTASTAT
$occurs( pmon^nam^g ), !NCPSTASTAT
srv^class, !NCPSTASTAT
$occurs( srv^class ), !NCPSTASTAT
ncp^rqst, !NCPSTASTAT
$len( ncp^rqst ), !NCPSTASTAT
$len( ncp^resp^struct^def ), !NCPSTASTAT
cnt^read ); !NCPSTASTAT
!NCPSTASTAT
if not err then !NCPSTASTAT
begin !NCPSTASTAT
@ncp^resp^tkn := @ncp^rqst.dynamic^var1.dynamic^area; !NCPSTASTAT
@ncp^resp := @ncp^resp^tkn.var^data; !NCPSTASTAT
if ncp^resp.resp^code <> ncp^err^ok then !NCPSTASTAT
begin !NCPSTASTAT
! server NCP returned error !!NCPSTASTAT
end !NCPSTASTAT
else !NCPSTASTAT
begin !NCPSTASTAT
if ncp^rqst.static.max^resps >= 1 then !NCPSTASTAT
begin !NCPSTASTAT
! print field info !!NCPSTASTAT
buff ':=' " CURRENT LOGICAL"; !NCPSTASTAT
call write( term^num, buff, 36 ); !NCPSTASTAT
buff ':=' "STATION STATE STATE " & !NCPSTASTAT
" QUEUE COUNT"; !NCPSTASTAT
call write( term^num, buff, 50 ); !NCPSTASTAT
buff ':=' "---------------- ------- -------" & !NCPSTASTAT
" -----------"; !NCPSTASTAT
call write( term^num, buff, 50 ); !NCPSTASTAT
end; !NCPSTASTAT
!NCPSTASTAT
! loop parse response STATION data and show the STATES !!NCPSTASTAT
use x; x := 0; !NCPSTASTAT
while x < ncp^rqst.static.max^resps do !NCPSTASTAT
begin !NCPSTASTAT
@ncp^resp^stat := @ncp^resp.resp^data[16]; !NCPSTASTAT
!NCPSTASTAT
! check current state !!NCPSTASTAT
case ncp^resp^stat.current^state of !NCPSTASTAT
begin !NCPSTASTAT
ncp^val^abnormal -> cur^state ':=' "ABNORMAL "; !NCPSTASTAT
ncp^val^started -> cur^state ':=' "STARTED "; !NCPSTASTAT
ncp^val^starting -> cur^state ':=' "STARTING "; !NCPSTASTAT
ncp^val^stopped -> cur^state ':=' "STOPPED "; !NCPSTASTAT
ncp^val^stopping -> cur^state ':=' "STOPPING "; !NCPSTASTAT
ncp^val^suspended -> cur^state ':=' "SUSPENDED"; !NCPSTASTAT
otherwise -> cur^state ':=' "UNKNOWN "; !NCPSTASTAT
end; !NCPSTASTAT
! check logical state !!NCPSTASTAT
case ncp^resp^stat.logical^state of !NCPSTASTAT
begin !NCPSTASTAT
ncp^val^abnormal -> log^state ':=' "ABNORMAL "; !NCPSTASTAT
ncp^val^started -> log^state ':=' "STARTED "; !NCPSTASTAT
ncp^val^starting -> log^state ':=' "STARTING "; !NCPSTASTAT
ncp^val^stopped -> log^state ':=' "STOPPED "; !NCPSTASTAT
ncp^val^stopping -> log^state ':=' "STOPPING "; !NCPSTASTAT
ncp^val^suspended -> log^state ':=' "SUSPENDED"; !NCPSTASTAT
otherwise -> log^state ':=' "UNKNOWN "; !NCPSTASTAT
end; !NCPSTASTAT
!NCPSTASTAT
! convert queue count to ascii !!NCPSTASTAT
call numout( q^cnt, ncp^resp^stat.queue^count, !NCPSTASTAT
10, $occurs( q^cnt ) ); !NCPSTASTAT
!NCPSTASTAT
buff ':=' ncp^resp.resp^obj for !NCPSTASTAT
$len( ncp^resp.resp^obj ) & " " & !NCPSTASTAT
cur^state for $occurs( cur^state ) & " " & !NCPSTASTAT
log^state for $occurs( log^state ) & !NCPSTASTAT
" " & !NCPSTASTAT
q^cnt for $occurs( q^cnt ); !NCPSTASTAT
call write( term^num, buff, 53 ); !NCPSTASTAT
!NCPSTASTAT
! position on next STATION data !!NCPSTASTAT
if ncp^rqst.static.max^resps > 1 then !NCPSTASTAT
@ncp^resp := @ncp^resp.resp^data[28]; !NCPSTASTAT
!NCPSTASTAT
! increment counter !!NCPSTASTAT
x := x + 1; !NCPSTASTAT
end; !NCPSTASTAT
drop x; !NCPSTASTAT
end; !NCPSTASTAT
end !NCPSTASTAT
else !NCPSTASTAT
if err = 233 then !NCPSTASTAT
begin !NCPSTASTAT
! PATHSEND error, get error details !!NCPSTASTAT
call serverclass_send_info_( err, file^err ); !NCPSTASTAT
!NCPSTASTAT
! convert errors to ascii !!NCPSTASTAT
call numout( err^s, err, 10, $occurs( err^s ) ); !NCPSTASTAT
call numout( file^err^s, file^err, 10, $occurs( file^err^s ) );!NCPSTASTAT
!NCPSTASTAT
buff ':=' "PATHSEND error: " & err^s for $occurs( err^s ) & !NCPSTASTAT
", file error: " & file^err^s for $occurs( file^err^s ); !NCPSTASTAT
call write( term^num, buff, 40 ); !NCPSTASTAT
end !NCPSTASTAT
else !NCPSTASTAT
begin !NCPSTASTAT
! <> 233, unknown pathsend error !!NCPSTASTAT
end; !NCPSTASTAT
!NCPSTASTAT
! close hometerm !!NCPSTASTAT
call close( term^num ); !NCPSTASTAT
!NCPSTASTAT
end; !NCPSTASTAT
Uros