various bug fixes
This commit is contained in:
parent
272fd660b4
commit
78802e6993
10 changed files with 89 additions and 9 deletions
|
|
@ -64,6 +64,10 @@ plumbsendtofid(Fid *fid, Plumbmsg *m)
|
|||
char *buf;
|
||||
int n;
|
||||
|
||||
if(fid == nil){
|
||||
werrstr("invalid fid");
|
||||
return -1;
|
||||
}
|
||||
buf = plumbpack(m, &n);
|
||||
if(buf == nil)
|
||||
return -1;
|
||||
|
|
@ -75,6 +79,10 @@ plumbsendtofid(Fid *fid, Plumbmsg *m)
|
|||
int
|
||||
plumbsend(int fd, Plumbmsg *m)
|
||||
{
|
||||
if(fd == -1){
|
||||
werrstr("invalid fd");
|
||||
return -1;
|
||||
}
|
||||
if(fd != pfd){
|
||||
werrstr("fd is not the plumber");
|
||||
return -1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue