aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2000-02-22 04:04:41 +0000
committerEric S. Raymond <esr@thyrsus.com>2000-02-22 04:04:41 +0000
commit83cec868b20841b81fd0c3b59d8e98c81f5608ea (patch)
treee9accfafaa30bc84d0efccb8e993289eb168fdee
parent6f390a7fe4dfd8640c9866ad5d47ca2ffff47105 (diff)
downloadfetchmail-83cec868b20841b81fd0c3b59d8e98c81f5608ea.tar.gz
fetchmail-83cec868b20841b81fd0c3b59d8e98c81f5608ea.tar.bz2
fetchmail-83cec868b20841b81fd0c3b59d8e98c81f5608ea.zip
Tweak in lexical analysis.
svn path=/trunk/; revision=2764
-rw-r--r--NEWS1
-rw-r--r--rcfile_l.l2
-rw-r--r--socket.c2
3 files changed, 3 insertions, 2 deletions
diff --git a/NEWS b/NEWS
index ebd74527..12caa84d 100644
--- a/NEWS
+++ b/NEWS
@@ -7,6 +7,7 @@
* Only emit progress dots when stdout is connected to a tty.
* Fix for GNATS bug 16468, "INET6 breaks fetchmail preconnect"
by Munechika SUMIKAWA <sumikawa@ebina.hitachi.co.jp>.
+* Lexical analyzer now understands that -?[0-9]*[a-zA-Z] is not a number.
fetchmail-5.2.8 (Mon Feb 14 19:16:46 EST 2000), 18571 lines:
diff --git a/rcfile_l.l b/rcfile_l.l
index 91b82d88..32e274cc 100644
--- a/rcfile_l.l
+++ b/rcfile_l.l
@@ -177,7 +177,7 @@ options {/* EMPTY */}
(#.*)?\\?\n { prc_lineno++; } /* newline is ignored */
--?[0-9]+ { yylval.number = atoi(yytext); return NUMBER; }
+-?[0-9]+/[^a-zA-Z] { yylval.number = atoi(yytext); return NUMBER; }
[^=;:, \t\r\n]+ {
char buf[MSGBUFSIZE];
diff --git a/socket.c b/socket.c
index 9501b1eb..3040a5fe 100644
--- a/socket.c
+++ b/socket.c
@@ -669,7 +669,7 @@ int SockClose(int sock)
* This stops sends but allows receives (effectively, it sends a
* TCP <FIN>).
*/
- if (shutdown(sock, 1) == SUCCESS)
+ if (shutdown(sock, 1) == 0)
/* If there is any data still waiting in the queue, discard it.
* Call recv() until either it returns 0 (meaning we received a FIN)
* or any error occurs. This makes sure all data sent by the other