]> granicus.if.org Git - neomutt/commitdiff
fix some types
authorRichard Russon <rich@flatcap.org>
Tue, 24 Oct 2017 18:08:08 +0000 (19:08 +0100)
committerRichard Russon <rich@flatcap.org>
Sat, 28 Oct 2017 03:36:50 +0000 (04:36 +0100)
imap/command.c
imap/imap.c
imap/imap.h
imap/imap_private.h
imap/utf7.c
imap/util.c

index 9a9e0952f1335f809713bd42d6469f15f5144d6c..fd3087e06cdadaecc7a25df7a9c6e726c863bd43 100644 (file)
@@ -991,7 +991,7 @@ int imap_cmd_step(struct ImapData *idata)
  * @retval 1 if the command result was OK
  * @retval 0 if NO or BAD
  */
-int imap_code(const char *s)
+bool imap_code(const char *s)
 {
   return cmd_status(s) == IMAP_CMD_OK;
 }
index 59241fb3e541e26b64490d091f4d371932d80541..688dc6b21ea20f93bc374feff1530654e7824ec2 100644 (file)
@@ -1452,7 +1452,7 @@ int imap_status(char *path, int queue)
  *
  * return cached mailbox stats or NULL if create is 0
  */
-struct ImapStatus *imap_mboxcache_get(struct ImapData *idata, const char *mbox, int create)
+struct ImapStatus *imap_mboxcache_get(struct ImapData *idata, const char *mbox, bool create)
 {
   struct ImapStatus *status = NULL;
 #ifdef USE_HCACHE
@@ -1551,7 +1551,7 @@ int imap_search(struct Context *ctx, const struct Pattern *pat)
   return 0;
 }
 
-int imap_subscribe(char *path, int subscribe)
+int imap_subscribe(char *path, bool subscribe)
 {
   struct ImapData *idata = NULL;
   char buf[LONG_STRING];
index e5d890b8f98a9eea8b3b14ba7da9693ae25176c4..c7ba675a2bfde8a50886d0a134d97c277f234589 100644 (file)
@@ -52,7 +52,7 @@ int imap_close_mailbox(struct Context *ctx);
 int imap_buffy_check(int force, int check_stats);
 int imap_status(char *path, int queue);
 int imap_search(struct Context *ctx, const struct Pattern *pat);
-int imap_subscribe(char *path, int subscribe);
+int imap_subscribe(char *path, bool subscribe);
 int imap_complete(char *dest, size_t dlen, char *path);
 int imap_fast_trash(struct Context *ctx, char *dest);
 
index 4cdaa3f4eab0bb79595b0e499edb3c46d993bf12..50a83a42dfd41b22b1c6e742ec89f6ffa56672e5 100644 (file)
@@ -269,7 +269,7 @@ struct ImapData
 int imap_check(struct ImapData *idata, int force);
 int imap_create_mailbox(struct ImapData *idata, char *mailbox);
 int imap_rename_mailbox(struct ImapData *idata, struct ImapMbox *mx, const char *newname);
-struct ImapStatus *imap_mboxcache_get(struct ImapData *idata, const char *mbox, int create);
+struct ImapStatus *imap_mboxcache_get(struct ImapData *idata, const char *mbox, bool create);
 void imap_mboxcache_free(struct ImapData *idata);
 int imap_exec_msgset(struct ImapData *idata, const char *pre, const char *post,
                      int flag, int changed, int invert);
@@ -289,7 +289,7 @@ int imap_authenticate(struct ImapData *idata);
 int imap_cmd_start(struct ImapData *idata, const char *cmd);
 int imap_cmd_step(struct ImapData *idata);
 void imap_cmd_finish(struct ImapData *idata);
-int imap_code(const char *s);
+bool imap_code(const char *s);
 const char *imap_cmd_trailer(struct ImapData *idata);
 int imap_exec(struct ImapData *idata, const char *cmd, int flags);
 int imap_cmd_idle(struct ImapData *idata);
index 62da77252063d9848bc8685c4198f8067dd7c404..073d64785e7ee21640d734f61624433cf07a48ad 100644 (file)
@@ -145,7 +145,7 @@ static char *utf7_to_utf8(const char *u7, size_t u7len, char **u8, size_t *u8len
 
 bail:
   FREE(&buf);
-  return 0;
+  return NULL;
 }
 
 /**
@@ -278,7 +278,7 @@ static char *utf8_to_utf7(const char *u8, size_t u8len, char **u7, size_t *u7len
 
 bail:
   FREE(&buf);
-  return 0;
+  return NULL;
 }
 
 void imap_utf_encode(struct ImapData *idata, char **s)
index 04d6badefe14c49dfe80e1bd6e64792e2838f689..c92bc394a7b9cf7935e87dafa29bae613d067a7b 100644 (file)
@@ -836,7 +836,7 @@ int imap_wait_keepalive(pid_t pid)
   sigset_t oldmask;
   int rc;
 
-  short imap_passive = option(OPT_IMAP_PASSIVE);
+  bool imap_passive = option(OPT_IMAP_PASSIVE);
 
   set_option(OPT_IMAP_PASSIVE);
   set_option(OPT_KEEP_QUIET);