[Pkg-wmaker-commits] [wmbiff] 30/84: config.h

Doug Torrance dtorrance-guest at moszumanska.debian.org
Thu Aug 20 03:01:51 UTC 2015


This is an automated email from the git hooks/post-receive script.

dtorrance-guest pushed a commit to tag wmbiff_0_4_10
in repository wmbiff.

commit 64057a75473e47af1ab77735b7b2cc734adcb7aa
Author: bluehal <bluehal>
Date:   Fri Jun 21 04:31:31 2002 +0000

    config.h
---
 wmbiff/LicqClient.c    | 16 ++++++++++------
 wmbiff/ShellClient.c   | 10 ++++++++--
 wmbiff/charutil.c      |  6 +++++-
 wmbiff/maildirClient.c | 10 +++++++---
 wmbiff/mboxClient.c    |  8 ++++++--
 wmbiff/passwordMgr.c   |  5 +++++
 wmbiff/test_wmbiff.c   |  5 +++++
 7 files changed, 46 insertions(+), 14 deletions(-)

diff --git a/wmbiff/LicqClient.c b/wmbiff/LicqClient.c
index 722c51d..2b22af1 100644
--- a/wmbiff/LicqClient.c
+++ b/wmbiff/LicqClient.c
@@ -1,13 +1,17 @@
-/* $Id: LicqClient.c,v 1.10 2002/04/20 09:12:35 bluehal Exp $ */
+/* $Id: LicqClient.c,v 1.11 2002/06/21 04:31:31 bluehal Exp $ */
 /* Author : Yong-iL Joh ( tolkien at mizi.com )
    Modified: Jorge Garc�a ( Jorge.Garcia at uv.es )
  * 
  * LICQ checker.
  *
- * Last Updated : $Date: 2002/04/20 09:12:35 $
+ * Last Updated : $Date: 2002/06/21 04:31:31 $
  *
  */
 
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include "Client.h"
 #include <sys/stat.h>
 #include <utime.h>
@@ -18,13 +22,13 @@
 
 #define PCM     (pc->u).mbox
 
-int licqCheckHistory(Pop3 pc)
+int licqCheckHistory( /*@notnull@ */ Pop3 pc)
 {
 	struct utimbuf ut;
 
 	DM(pc, DEBUG_INFO, ">Mailbox: '%s'\n", pc->path);
 
-	if (fileHasChanged(pc->path, &ut.actime, &PCM.mtime, &PCM.size)
+	if (fileHasChanged(pc->path, &ut.actime, &PCM.mtime, &PCM.size) != 0
 		|| pc->OldMsgs < 0) {
 		FILE *F;
 		char buf[1024];
@@ -39,7 +43,7 @@ int licqCheckHistory(Pop3 pc)
 				count_status++;
 			}
 		}
-		fclose(F);
+		(void) fclose(F);
 
 		pc->TotalMsgs = count_status * 2;
 		pc->UnreadMsgs = pc->TotalMsgs - count_status;
@@ -57,7 +61,7 @@ int licqCheckHistory(Pop3 pc)
 	return 0;
 }
 
-int licqCreate(Pop3 pc, char *str)
+int licqCreate( /*@notnull@ */ Pop3 pc, const char *str)
 {
 	/* LICQ format: licq:fullpathname */
 
diff --git a/wmbiff/ShellClient.c b/wmbiff/ShellClient.c
index 465fb6a..e5e3cfc 100644
--- a/wmbiff/ShellClient.c
+++ b/wmbiff/ShellClient.c
@@ -8,6 +8,10 @@
  *
  */
 
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include "Client.h"
 #include <errno.h>
 #include <string.h>
@@ -196,7 +200,7 @@ int shellCmdCheck(Pop3 pc)
 	return (0);
 }
 
-int shellCreate(Pop3 pc, const char *str)
+int shellCreate( /*@notnull@ */ Pop3 pc, const char *str)
 {
 	/* SHELL format: shell:::/path/to/script */
 	const char *reserved1, *reserved2, *commandline;
@@ -208,6 +212,8 @@ int shellCreate(Pop3 pc, const char *str)
 	pc->checkMail = shellCmdCheck;
 	reserved1 = str + 6;		/* shell:>:: */
 
+	assert(strncasecmp("shell:", str, 6) == 0);
+
 	reserved2 = index(reserved1, ':');
 	if (reserved2 == NULL) {
 		SH_DM(pc, DEBUG_ERROR, "unable to parse '%s', expecting ':'", str);
@@ -224,8 +230,8 @@ int shellCreate(Pop3 pc, const char *str)
 	commandline++;				/* shell:::> */
 
 	/* good thing strcpy handles overlapping regions */
-	strcpy(pc->path, commandline);
 	SH_DM(pc, DEBUG_INFO, "path= '%s'\n", commandline);
+	strcpy(pc->path, commandline);
 	return 0;
 }
 
diff --git a/wmbiff/charutil.c b/wmbiff/charutil.c
index 9d7e924..e3300de 100644
--- a/wmbiff/charutil.c
+++ b/wmbiff/charutil.c
@@ -1,4 +1,8 @@
-/* $Id: charutil.c,v 1.11 2002/06/01 06:02:06 bluehal Exp $ */
+/* $Id: charutil.c,v 1.12 2002/06/21 04:31:31 bluehal Exp $ */
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include <stdlib.h>
 #include <stdio.h>
 #include <string.h>
diff --git a/wmbiff/maildirClient.c b/wmbiff/maildirClient.c
index 05f2c52..6071520 100644
--- a/wmbiff/maildirClient.c
+++ b/wmbiff/maildirClient.c
@@ -1,14 +1,18 @@
-/* $Id: maildirClient.c,v 1.7 2002/04/09 07:45:52 bluehal Exp $ */
+/* $Id: maildirClient.c,v 1.8 2002/06/21 04:31:31 bluehal Exp $ */
 /* Author : Yong-iL Joh ( tolkien at mizi.com )
    Modified : Jorge Garc�a ( Jorge.Garcia at uv.es )
    Modified : Dwayne C. Litzenberger ( dlitz at dlitz.net )
  * 
  * Maildir checker.
  *
- * Last Updated : $Date: 2002/04/09 07:45:52 $
+ * Last Updated : $Date: 2002/06/21 04:31:31 $
  *
  */
 
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include "Client.h"
 #include <sys/stat.h>
 #include <dirent.h>
@@ -115,7 +119,7 @@ int maildirCheckHistory(Pop3 pc)
 	return 0;
 }
 
-int maildirCreate(Pop3 pc, char *str)
+int maildirCreate(Pop3 pc, const char *str)
 {
 	/* Maildir format: maildir:fullpathname */
 
diff --git a/wmbiff/mboxClient.c b/wmbiff/mboxClient.c
index 0010b93..eac4103 100644
--- a/wmbiff/mboxClient.c
+++ b/wmbiff/mboxClient.c
@@ -1,4 +1,4 @@
-/* $Id: mboxClient.c,v 1.14 2002/06/01 06:02:06 bluehal Exp $ */
+/* $Id: mboxClient.c,v 1.15 2002/06/21 04:31:31 bluehal Exp $ */
 /* Author:		Yong-iL Joh <tolkien at mizi.com>
    Modified:	Jorge Garc�a <Jorge.Garcia at uv.es>
    			 	Rob Funk <rfunk at funknet.net>
@@ -6,10 +6,14 @@
  * 
  * MBOX checker.
  *
- * Last Updated : $Date: 2002/06/01 06:02:06 $
+ * Last Updated : $Date: 2002/06/21 04:31:31 $
  *
  */
 
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include "Client.h"
 #include <sys/stat.h>
 #include <errno.h>
diff --git a/wmbiff/passwordMgr.c b/wmbiff/passwordMgr.c
index 2d991f1..59f6b99 100644
--- a/wmbiff/passwordMgr.c
+++ b/wmbiff/passwordMgr.c
@@ -21,6 +21,11 @@
    again. This might be poor if the askpass program is
    replaced with something non-interactive. */
 
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+
 #include "passwordMgr.h"
 #include "Client.h"
 #include "charutil.h"			/* chomp */
diff --git a/wmbiff/test_wmbiff.c b/wmbiff/test_wmbiff.c
index f4cbfba..48b0462 100644
--- a/wmbiff/test_wmbiff.c
+++ b/wmbiff/test_wmbiff.c
@@ -1,3 +1,7 @@
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include "Client.h"
 #include "passwordMgr.h"
 
@@ -38,6 +42,7 @@ int test_backtickExpand(void) {
 int test_passwordMgr(void) {
 	const char *b;
 	mbox_t m;
+    strcpy(m.label, "x");
 
 	/* sh is almost certainly conforming; owned by root, etc. */
 	if (!permissions_ok(NULL, "/bin/sh")) {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-wmaker/wmbiff.git



More information about the Pkg-wmaker-commits mailing list