bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: oskit-mach: device_write


From: Thomas Bushnell, BSG
Subject: Re: oskit-mach: device_write
Date: 10 Mar 2002 12:09:18 -0800
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.1

Daniel Wagner <wagi@gmx.ch> writes:

> Calling device_write with an invalid data_count, device_write will return 
> an error (D_INVALID_SIZE). I didn't checked the return value, instead
> I tested for the bytes_written and of course there's only a bogus 
> value.

This is a general rule for MiG interfaces; if you get an error, then
the OUT parameters aren't filled in at all, so they stay with what
they were before (which often is just whatever was last in some random
location on the stack).  

This is, of course, utterly intolerable, but it's what we get for
using C.

Thomas



reply via email to

[Prev in Thread] Current Thread [Next in Thread]