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

Bug#485135: To fail or misbehave



> Please explain. In C++ there is no implicit conversion between int and
> char *.

Exactly. So if you check the return value then the compiler will fail (like in the test case above) and you are lucky to notice the problem.

But if you don't check it and rely on the function to do what it has to do (i.e. write the result into the buffer in the argument) then you silently get a buffer with undefined data back (most likely unchanged).

For my own code I added a workaround, testing _GNU_SOURCE and making a different call but it should be fixed upstream.

-- 
GMX startet ShortView.de. Hier findest Du Leute mit Deinen Interessen!
Jetzt dabei sein: http://www.shortview.de/wasistshortview.php?mc=sv_ext_mf@gmx



Reply to: