NetIPC 3000/XL Programmer's Reference Manual (5958-8600)
Table Of Contents
- 1 NetIPC Fundamentals
- 2 Cross-System NetIPC
- 3 NetIPC Intrinsics
- 4 NetIPC Examples
- A IPC Interpreter (IPCINT)
- B Cause and Diagnostic Codes
- C ErrorMessages
- D Migration From PTOP to NetIPC and RPM
- E C Program Language Considerations

Appendix D 225
Migration From PTOP to NetIPC and RPM
Example: Client-Server Application
info: packed array [1..infolength ] of char;
opt: packed array [1..maxoptlength ] of char;
rpmflags: packed array [0..31] of boolean;
progdesc: array [1..8] of shortint;
buf: buftype;
clientnodelength: shortint;
loclength: shortint;
prognamelength: shortint;
socketdesc: integer;
vcdesc: integer;
status: shortint;
result: integer;
envnum: shortint;
i: integer;
procedure NSINFO; intrinsic; {NS intrinsic }
procedure IPCCREATE; intrinsic; {NetIPC intrinsics}
procedure IPCNAME; intrinsic;
procedure IPCNAMERASE; intrinsic;
procedure IPCRECVCN; intrinsic;
procedure IPCSEND; intrinsic;
procedure IPCRECV; intrinsic;
procedure IPCSHUTDOWN; intrinsic;
procedure INITOPT; intrinsic;
procedure ADDOPT; intrinsic;
procedure RPMCREATE; intrinsic; {RPM intrinsics }
procedure RPMKILL; intrinsic;
procedure ERROR( msg: msgtype; result: integer );
{----------------------------------------------------------------}
{ ERROR prints out an error message and an associated NetIPC or }
{ RPM result code, and then goes to the error exit to terminate }
{ the program. Because the server was created with the dependent}
{ flag, the server will automatically terminate. Any NetIPC }
{ objects (socket, socket name, or virtual circuit) will also be }
{ deleted at termination. }
{----------------------------------------------------------------}
begin
writeln( 'Client: ', msg, 'Result = ', result:3 );
goto 1;
end;
procedure RECV( vcdesc: integer;
var buf: buftype;
length: integer;
var result: integer );
var nextbufchar: integer;
recvlength: integer;