summaryrefslogtreecommitdiff
path: root/src/locale
diff options
context:
space:
mode:
authorJakob Kaivo <jkk@ung.org>2024-01-31 15:54:38 -0500
committerJakob Kaivo <jkk@ung.org>2024-01-31 15:54:38 -0500
commit57fd57ab4005e37bfab4bf7c637eecc1eb5445b5 (patch)
treea5cc5b9ad040955a0a7247091cbc542f297229bb /src/locale
parent1dcdfdc0141e94b57b80526ca917b1228fe53f53 (diff)
clean up UB detection
Diffstat (limited to 'src/locale')
-rw-r--r--src/locale/localeconv.c1
-rw-r--r--src/locale/setlocale.c1
2 files changed, 2 insertions, 0 deletions
diff --git a/src/locale/localeconv.c b/src/locale/localeconv.c
index ba4687d9..4e87bfb3 100644
--- a/src/locale/localeconv.c
+++ b/src/locale/localeconv.c
@@ -11,6 +11,7 @@ struct lconv * localeconv(void)
/*
RETURN_SUCCESS(a pointer to a filled-in STRUCTDEF(lconv) for the current locale);
*/
+ /* TODO: mark return value read-only */
return &(__get_locale()->lconv);
}
diff --git a/src/locale/setlocale.c b/src/locale/setlocale.c
index ab355dc6..521b118e 100644
--- a/src/locale/setlocale.c
+++ b/src/locale/setlocale.c
@@ -41,6 +41,7 @@ char * setlocale(int category, const char *locale)
default: return NULL;
}
+ /* TODO: mark return value read-only */
return __load_locale(l, mask, locale);
}