Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

If printf can write some bytes but not all of them. The C documentation is explicit:

> a negative value if an output error occurred

So in your case that's an error and printf returns a negative value. But yes, how many bytes were written is a lost information.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: