summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEd Schouten <ed@FreeBSD.org>2009-07-14 09:19:33 +0000
committerEd Schouten <ed@FreeBSD.org>2009-07-14 09:19:33 +0000
commit523a386d233fdba474e22adcc2b981dae6f3923a (patch)
tree6194ada65ae4540ce8451f20116b7216109fe600
parent3d22427cff0849b71e496010c8433961a6e2551c (diff)
Notes
-rw-r--r--usr.bin/mklocale/yacc.y4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/mklocale/yacc.y b/usr.bin/mklocale/yacc.y
index 4024f6720227..344af220cf6b 100644
--- a/usr.bin/mklocale/yacc.y
+++ b/usr.bin/mklocale/yacc.y
@@ -730,8 +730,8 @@ dump_tables()
/*
* PART 6: And finally the variable data
*/
- if (fwrite(variable,
- ntohl(new_locale.variable_len), 1, fp) != 1) {
+ if (new_locale.variable_len != 0 &&
+ fwrite(variable, ntohl(new_locale.variable_len), 1, fp) != 1) {
perror(locale_file);
exit(1);
}