X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/70637f3fad9cb3cbc6f4bd8d89a32bc474fc38ad..aec3da7124a644558ae111ecf068f5f39a3216b3:/h/prototypes.h diff --git a/h/prototypes.h b/h/prototypes.h index 2a1132c7..0b40c0d5 100644 --- a/h/prototypes.h +++ b/h/prototypes.h @@ -7,7 +7,7 @@ /* * prototype from config.h */ -char *etcpath(char *); +char *etcpath(char *) NONNULL(1); /* * prototypes from the nmh subroutine library @@ -18,16 +18,17 @@ struct msgs_array; void add_profile_entry (const char *, const char *); void inform(char *fmt, ...) CHECK_PRINTF(1, 2); void adios (const char *, const char *, ...) CHECK_PRINTF(2, 3) NORETURN; +void die(const char *, ...) CHECK_PRINTF(1, 2) NORETURN; void admonish (char *, char *, ...) CHECK_PRINTF(2, 3); void advertise (const char *, char *, const char *, va_list) CHECK_PRINTF(3, 0); void advise (const char *, const char *, ...) CHECK_PRINTF(2, 3); -char **argsplit (char *, char **, int *); -void argsplit_msgarg (struct msgs_array *, char *, char **); -void argsplit_insert (struct msgs_array *, char *, char **); +char **argsplit (char *, char **, int *) NONNULL(1, 2); +void argsplit_msgarg (struct msgs_array *, char *, char **) NONNULL(1, 2, 3); +void argsplit_insert (struct msgs_array *, char *, char **) NONNULL(1, 2, 3); void arglist_free (char *, char **); -void ambigsw (const char *, const struct swit *); -int atooi(char *); -char **brkstring (char *, char *, char *); +void ambigsw (const char *, const struct swit *) NONNULL(1, 2); +int atooi(char *) NONNULL(1); +char **brkstring (char *, char *, char *) NONNULL(1); /* * Check to see if we can display a given character set natively. @@ -70,7 +71,7 @@ void discard (FILE *); * * Returns the decoded value, -1 if the conversion failed. */ -int decode_qp(unsigned char byte1, unsigned char byte2); +int decode_qp(unsigned char byte1, unsigned char byte2) CONST; int default_done (int); @@ -385,10 +386,10 @@ int sc_width(void); int build_form (char *, char *, int *, char *, char *, char *, char *, char *, char *); int sendsbr (char **, int, char *, char *, struct stat *, int, const char *); -int SOprintf (char *, ...); +int SOprintf (char *, ...) CHECK_PRINTF(1, 2); int what_now (char *, int, int, char *, char *, int, struct msgs *, char *, int, char *, int); -int WhatNow(int, char **); +int WhatNow(int, char **) NORETURN; /* Includes trailing NUL */