libgimpbase: fix declaration after statement and reset safecheck...49b4b1a5c2a4797f490a0e7e9eac1bcbb399a568
commit49b4b1a5c2a4797f490a0e7e9eac1bcbb399a568
authorJehan <jehan@girinstud.io>
Sun, 24 Jun 2018 23:04:01 +0000 (25 01:04 +0200)
committerJehan <jehan@girinstud.io>
Sun, 24 Jun 2018 23:14:15 +0000 (25 01:14 +0200)
tree1a850c87fdc2b4f658d05d4a808ee8f3da8bd5a1
parent559d9b89e348a6713dc0650577330f93fc8ed0bb
libgimpbase: fix declaration after statement and reset safecheck...

... after each successful read().
I completely missed this declaration after a statement during the review
of !13 even though I saw another similar issue!

Also let's reset the error counter to 0 each time a successful read()
happens so that we can continue reading even if a lot of EINTR were to
happen, as long as we globally go forward. Only consecutive errors
increment the counter.

Finally add a small comment to explain why we let EINTR pass instead of
breaking directly.
libgimpbase/gimputils.c