chiark / gitweb /
keymap: Tolerate invalid entries in keymaps
[elogind.git] / src / shared / util.h
index e1d4735ee38dec94278118343fd89d6b0cba6e69..77d28751f0a40937e455748542c6480e0cac074d 100644 (file)
@@ -141,7 +141,7 @@ static inline bool isempty(const char *p) {
         return !p || !p[0];
 }
 
-bool endswith(const char *s, const char *postfix);
+char *endswith(const char *s, const char *postfix);
 bool startswith(const char *s, const char *prefix);
 bool startswith_no_case(const char *s, const char *prefix);
 
@@ -384,10 +384,11 @@ int status_welcome(void);
 
 int fd_columns(int fd);
 unsigned columns(void);
-unsigned columns_uncached(void);
-
 int fd_lines(int fd);
 unsigned lines(void);
+void columns_lines_cache_reset(int _unused_ signum);
+
+bool on_tty(void);
 
 int running_in_chroot(void);
 
@@ -557,3 +558,8 @@ _malloc_ static inline void *memdup_multiply(const void *p, size_t a, size_t b)
 
         return memdup(p, a * b);
 }
+
+bool filename_is_safe(const char *p);
+bool string_is_safe(const char *p);
+
+int parse_timestamp(const char *t, usec_t *usec);