* movemail.c: (DIRECTORY_SEP, IS_DIRECTORY_SEP, DONE, IS_FROM_LINE):
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 21 Feb 2011 18:37:35 +0000 (10:37 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 21 Feb 2011 18:37:35 +0000 (10:37 -0800)
Remove unused macros.
* pop.c (index): Remove unused macro.
(KPOP_PORT): Define only if KERBEROS is defined.

lib-src/ChangeLog
lib-src/movemail.c
lib-src/pop.c

index f2f2c0a..53983a9 100644 (file)
@@ -2,6 +2,10 @@
 
        * movemail.c (main, pop_retr): Rename locals to avoid shadowing.
        (progname, sfi, sfo, ibuffer, obuffer): Remove unused vars.
+       (DIRECTORY_SEP, IS_DIRECTORY_SEP, DONE, IS_FROM_LINE):
+       Remove unused macros.
+       * pop.c (index): Remove unused macro.
+       (KPOP_PORT): Define only if KERBEROS is defined.
 
        Declare file-scope functions and variables static if not exported.
        This is more consistent, and is nicer with gcc -Wstrict-prototypes.
index bb93d84..a5084f2 100644 (file)
@@ -80,13 +80,6 @@ along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.  */
 #undef access
 #endif /* MSDOS */
 
-#ifndef DIRECTORY_SEP
-#define DIRECTORY_SEP '/'
-#endif
-#ifndef IS_DIRECTORY_SEP
-#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)
-#endif
-
 #ifdef WINDOWSNT
 #include "ntlib.h"
 #undef access
@@ -670,7 +663,6 @@ xmalloc (unsigned int size)
 
 #define NOTOK (-1)
 #define OK 0
-#define DONE 1
 
 static char Errmsg[200];       /* POP errors, at least, can exceed
                                   the original length of 80.  */
@@ -855,13 +847,6 @@ pop_retr (popserver server, int msgno, FILE *arg)
   return (OK);
 }
 
-/* Do this as a macro instead of using strcmp to save on execution time. */
-#define IS_FROM_LINE(a) ((a[0] == 'F') \
-                        && (a[1] == 'r') \
-                        && (a[2] == 'o') \
-                        && (a[3] == 'm') \
-                        && (a[4] == ' '))
-
 static int
 mbx_write (char *line, int len, FILE *mbf)
 {
index a3fda09..159926e 100644 (file)
@@ -67,7 +67,6 @@ extern struct servent *hes_getservbyname (/* char *, char * */);
 #include <stdio.h>
 #ifdef STDC_HEADERS
 #include <string.h>
-#define index strchr
 #endif
 #include <unistd.h>
 
@@ -122,9 +121,9 @@ static char *find_crlf (char *, int);
                                   to be bigger than the original
                                   value of 80 */
 #define POP_PORT 110
-#define KPOP_PORT 1109
 #define POP_SERVICE "pop3"     /* we don't want the POP2 port! */
 #ifdef KERBEROS
+#define KPOP_PORT 1109
 #define KPOP_SERVICE "kpop"    /* never used: look for 20060515 to see why */
 #endif