aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Richardson <arichardson@FreeBSD.org>2020-07-15 12:07:53 +0000
committerAlex Richardson <arichardson@FreeBSD.org>2020-07-15 12:07:53 +0000
commit2becc9efb56b82826b73d07875b6ea75912a5d68 (patch)
treeb9fc7941def2f3de83d3787a86d668ee6e94cac8
parenta9ea00474518545efea1b428eaeb5a1ed67eeba2 (diff)
downloadsrc-2becc9efb56b82826b73d07875b6ea75912a5d68.tar.gz
src-2becc9efb56b82826b73d07875b6ea75912a5d68.zip
Add missing newline and return in localedef error message
I hit those error messages when using a localedef built against headers that don't match the target system (cross-building from a Linux host). This problem will be fixed in the next commit.
Notes
Notes: svn path=/head/; revision=363217
-rw-r--r--usr.bin/localedef/collate.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/localedef/collate.c b/usr.bin/localedef/collate.c
index 33e97ae9fb20..70e7272625a0 100644
--- a/usr.bin/localedef/collate.c
+++ b/usr.bin/localedef/collate.c
@@ -850,7 +850,8 @@ void
add_order_directive(void)
{
if (collinfo.directive_count >= COLL_WEIGHTS_MAX) {
- fprintf(stderr,"too many directives (max %d)", COLL_WEIGHTS_MAX);
+ fprintf(stderr, "too many directives (max %d)\n", COLL_WEIGHTS_MAX);
+ return;
}
collinfo.directive_count++;
}
@@ -859,7 +860,7 @@ static void
add_order_pri(int32_t ref)
{
if (curr_weight >= NUM_WT) {
- fprintf(stderr,"too many weights (max %d)", NUM_WT);
+ fprintf(stderr, "too many weights (max %d)\n", NUM_WT);
return;
}
order_weights[curr_weight] = ref;