Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 Jan 2001 22:25:41 +0100 (CET)
From:      Michal Zapasnik <bigstar@astercity.net>
To:        Mikko Tyolajarvi <mikko@dynas.se>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: System functions in BSD and others *nix systems.
Message-ID:  <Pine.BSF.4.21.0101182219430.1262-100000@BS.home.astercity.net>
In-Reply-To: <200101181901.f0IJ1Le53616@explorer.rsa.com>

next in thread | previous in thread | raw e-mail | index | archive | help


On Thu, 18 Jan 2001, Mikko Tyolajarvi wrote:

> Two of them actually...
> 
> [...]
>
Yes, right. 
> >When i run ./one | ./two on FreeBSD i get 
> > I recive: 671473920
> >and sa on as i wrote on other tested OS it works fine.
> 
> Which is never a guarantee of program correctness :-)
> 
Huh ;]
> >Anyone know where the problem is?
> 
> You don't check the return values of any of the msg* function calls,
> which may have failed for various reasons.  If you do that, you may be
> able to find out what is going wrong.
> 
I do as you say , 
[...]
if (msgrcv(q, &msg, sizeof(msg), 0, 0) == -1)
{
   perror("msgrcv");
   exit(0);
}

And i have 
msgrcv: Invalid argument

I check in manual that is the flag [EINVAL] 
'msqid is not a valid message queue identifier.'

But if why it work on other OS and on FBSD not?, and what is vaild
in my queue identifer.

--
BS.






To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0101182219430.1262-100000>