Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F177460275
D58496.1794466155.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1017 B
Referenced Files
None
Subscribers
None
D58496.1794466155.diff
View Options
diff --git a/usr.bin/localedef/messages.c b/usr.bin/localedef/messages.c
--- a/usr.bin/localedef/messages.c
+++ b/usr.bin/localedef/messages.c
@@ -87,24 +87,29 @@
FILE *f;
char *ptr;
+ /*
+ * CLDR likes to add : separated lists for yesstr and nostr.
+ * Legacy Solaris code does not seem to grok this. Fix it.
+ */
+
if (msgs.yesstr == NULL) {
warn("missing field 'yesstr'");
msgs.yesstr = "";
+ } else {
+ ptr = strchr(__DECONST(char *, msgs.yesstr), ':');
+ if (ptr != NULL)
+ *ptr = 0;
}
+
if (msgs.nostr == NULL) {
warn("missing field 'nostr'");
msgs.nostr = "";
+ } else {
+ ptr = strchr(__DECONST(char *, msgs.nostr), ':');
+ if (ptr != NULL)
+ *ptr = 0;
}
- /*
- * CLDR likes to add : separated lists for yesstr and nostr.
- * Legacy Solaris code does not seem to grok this. Fix it.
- */
- if ((ptr = strchr(msgs.yesstr, ':')) != NULL)
- *ptr = 0;
- if ((ptr = strchr(msgs.nostr, ':')) != NULL)
- *ptr = 0;
-
if ((f = open_category()) == NULL) {
return;
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Nov 12, 6:49 AM (16 h, 2 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41672734
Default Alt Text
D58496.1794466155.diff (1017 B)
Attached To
Mode
D58496: localedef: Const correctness for C23
Attached
Detach File
Event Timeline