diff options
author | Mattias Andrée <maandree@member.fsf.org> | 2016-01-02 07:19:16 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@member.fsf.org> | 2016-01-02 07:19:16 +0100 |
commit | b841ac15a3a39532c6f48d921d0817bd61b80f55 (patch) | |
tree | 76ca4d5611f7a67a57a85b344fec42a48dfa48b9 /src/parse_10deg.c | |
parent | parser for 10deg (diff) | |
download | radharc-b841ac15a3a39532c6f48d921d0817bd61b80f55.tar.gz radharc-b841ac15a3a39532c6f48d921d0817bd61b80f55.tar.bz2 radharc-b841ac15a3a39532c6f48d921d0817bd61b80f55.tar.xz |
blackbody
Signed-off-by: Mattias Andrée <maandree@member.fsf.org>
Diffstat (limited to '')
-rw-r--r-- | src/parse_10deg.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/parse_10deg.c b/src/parse_10deg.c index 0b34050..e562be0 100644 --- a/src/parse_10deg.c +++ b/src/parse_10deg.c @@ -61,9 +61,11 @@ int main(void) if (write(1, xyrgb, sizeof(xyrgb)) < (ssize_t)sizeof(xyrgb)) return perror(""), 1; } + if (write(1, xyrgb, sizeof(xyrgb)) < (ssize_t)sizeof(xyrgb)) /* sugar */ + return perror(""), 1; if (fstat(1, &attr)) return perror(""), 1; - if ((size_t)(attr.st_size) != EXPECTED_ELEMENTS * 5 * sizeof(double)) + if ((size_t)(attr.st_size) != (EXPECTED_ELEMENTS + 1) * 5 * sizeof(double)) return 1; return 0; |