PDA

View Full Version : RPC problem with doc from freebsd.org


tsubasa
January 17th, 2009, 20:47
Hey, I have a problem



everythis is OK to the: cc msg_proc.c msg_svc.c -o msg_server

msg_proc.c:13: error: number of arguments doesnât match prototype
msg.h:22: error: prototype declaration

Can anyone help me solve this?

it's from RPC guide from this side
http://docs.freebsd.org/44doc/psd/22.rpcgen/paper.pdf

dap
January 22nd, 2009, 22:21
Hello,

The code shown in the PDF uses deprecated features but it should compile. I don't have time to dig in the article, could you post directly the code that doesn't work ?

trev
January 23rd, 2009, 12:03
msg_proc.c:13: error: number of arguments doesnât match prototype
msg.h:22: error: prototype declaration

On line 13 of msg_proc.c there is a function whose arguments do not match the number specified in the prototype of the function.

On line 22 of msg.h there is a definition of the function prototype.

Of course, if you have no idea what all that means, it probably won't help.

The problem is probably caused by the fact that something has changed since the guide was written and the code provided will no longer compile until it has been changed to accommodate the changes. If you solve this one, you may well find another similar problem further into the compile cycle.

tsubasa
January 24th, 2009, 12:38
actually I found mistake, and solved problem by myself ^^", there's mistake in msg_proc.c

changed in msg_proc.c

int *
printmessage_1_svc(char **msg, struct svc_req *rqstp)


Thanks for your help.