index 97e270a5761f071aeb3666b595b5cd6a8cbd4098..fc6a9bf5f34158605add585439848367deaefac5 100644 (file)
--- a/mktag.c
+++ b/mktag.c
// Read the signature
size = 0;
for (;;) {
- int ret = read(0, buffer + size, MAXSIZE - size);
- if (!ret)
+ int ret = xread(0, buffer + size, MAXSIZE - size);
+ if (ret <= 0)
break;
- if (ret < 0) {
- if (errno == EAGAIN)
- continue;
- break;
- }
size += ret;
}