aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1992-05-07 20:13:17 +0000
committerRichard M. Stallman1992-05-07 20:13:17 +0000
commitcecf0f21e15126db3afaeca4baf608b1bf413a10 (patch)
tree0c99f53209c3cfa7775898d586f3fc28000ffdd1
parentbc98c79cb71b16f5f1a934927d41c9af9ccb2d62 (diff)
downloademacs-cecf0f21e15126db3afaeca4baf608b1bf413a10.tar.gz
emacs-cecf0f21e15126db3afaeca4baf608b1bf413a10.zip
*** empty log message ***
-rw-r--r--lib-src/movemail.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib-src/movemail.c b/lib-src/movemail.c
index de766e6d609..271346a86a8 100644
--- a/lib-src/movemail.c
+++ b/lib-src/movemail.c
@@ -392,6 +392,7 @@ xmalloc (size)
392#include <netinet/in.h> 392#include <netinet/in.h>
393#include <netdb.h> 393#include <netdb.h>
394#include <stdio.h> 394#include <stdio.h>
395#include <pwd.h>
395 396
396#ifdef USG 397#ifdef USG
397#include <fcntl.h> 398#include <fcntl.h>
@@ -427,6 +428,9 @@ popmail (user, outfile)
427 register int i; 428 register int i;
428 int mbfi; 429 int mbfi;
429 FILE *mbf; 430 FILE *mbf;
431 struct passwd *pw = (struct passwd *) getpwuid (getuid ());
432 if (pw == NULL)
433 fatal ("cannot determine user name");
430 434
431 host = getenv ("MAILHOST"); 435 host = getenv ("MAILHOST");
432 if (host == NULL) 436 if (host == NULL)
@@ -445,7 +449,7 @@ popmail (user, outfile)
445 } 449 }
446 450
447 if (pop_command ("USER %s", user) == NOTOK 451 if (pop_command ("USER %s", user) == NOTOK
448 || pop_command ("RPOP %s", user) == NOTOK) 452 || pop_command ("RPOP %s", pw->pw_name) == NOTOK)
449 { 453 {
450 pop_command ("QUIT"); 454 pop_command ("QUIT");
451 fatal (Errmsg); 455 fatal (Errmsg);