On 30.03.2016 9:13, Pedro F. Giffuni wrote: > */ > + sverrno = 0; > if (file == NULL) {
It introduces the bug of touching errno. Previous code does it right because 'goto finish;' can't happen with (f < 0) where errno is restored later. The whole errno code is complex here for reading at least. It microoptimize errno handling by removing unnecessary assignment, but it does not gain much in reality. Better change for easy reading will be to set sverrno = errno; once right at the function enter and remove it in all other places. In any case errno touching should be backed out. -- http://ache.vniz.net/ _______________________________________________ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"