From afa00abb2b68205bee539d7947130d6b1b1ec6e9 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Thu, 1 Apr 2021 19:39:14 +0200 Subject: Hardened entire system By using the nonnull attribute and replace buffer-overflow-prone functions like strcpy, strcat and sprintf by strlcpy, strlcat and snprintf. --- libs/libtxt/keymap.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'libs/libtxt/keymap.h') diff --git a/libs/libtxt/keymap.h b/libs/libtxt/keymap.h index 9f1966e..4f5512f 100644 --- a/libs/libtxt/keymap.h +++ b/libs/libtxt/keymap.h @@ -3,6 +3,8 @@ #ifndef KEYMAP_H #define KEYMAP_H +#include + #define KEYMAP_LENGTH 90 struct keymap { @@ -11,6 +13,6 @@ struct keymap { char alt_map[KEYMAP_LENGTH]; }; -struct keymap *keymap_parse(const char *path); +struct keymap *keymap_parse(const char *path) NONNULL; #endif -- cgit v1.2.3