"du" in C

Andre Landwehr andre.landwehr at gmx.net
Fri Jul 12 17:33:02 CEST 2002


On Fri, Jul 12, 2002 at 05:24:23PM +0200, Jan-Benedict Glaw wrote:
> "Inappropriate ioctl for device" - Du mußt den mit /dev/sdXN machen,
> nicht mit einem fd auf eine Datei.

ah, so ist das...

> Code sieht falsch aus. "*blksize" bei der Benutzung sieht aus, als
> würdest Du das so stehen haben:
> 
> 	int	*blksize;
> 	....
> 	ioctl (fd, FIGETBSZ, blksize);
> 
> Du mußt aber einen Pointer auf eine int-Variable, für die Du Speicher
> hast, übergeben. Die libc besorgt Dir den nicht.

ok, überredet ;-)

> ...aber dafür mutß Du in Gruppe "disks" sein (zumindest bei Debian).

Womit der Ansatz für mich leider unbrauchbar ist :-((( Trotzdem
danke für den Code!

Andre

--
"The inside of a computer is as dumb as hell, but it goes like mad!"
(Physicist Richard Feynman)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lug-owl.de/pipermail/linux/attachments/20020712/64351962/attachment.sig>


More information about the Linux mailing list