diff src/client.c @ 183:c912e8288164 noffle

[svn] * src/client.c: Only bail out of fetching multiple articles if the connection fails. If we do get a status from the upstream server note it and see what is reported for the next article. Otherwise failure to retrieve one article will cause all successive article fetches to fail even through they would succeed if tried. * src/lock.c: Fix assert in lazy locking. If another noffle signalled us to release the lock at the next close, and then repeats the signal so that it arrives during LOCK_closeDatabases, the signal handler was trying to close the databases again.
author bears
date Tue, 15 May 2001 13:07:53 +0100
parents a43a528cfbe7
children fed1334d766b
line wrap: on
line diff
--- a/src/client.c	Thu May 10 17:07:46 2001 +0100
+++ b/src/client.c	Tue May 15 13:07:53 2001 +0100
@@ -1,7 +1,7 @@
 /*
   client.c
 
-  $Id: client.c 286 2001-05-10 16:07:46Z bears $
+  $Id: client.c 292 2001-05-15 12:07:53Z bears $
 */
 
 #if HAVE_CONFIG_H
@@ -1153,13 +1153,20 @@
     res = TRUE;
     while ( res && ( p = Utl_getLn( msgId, p ) ) )
     {
-        if ( getStat() != STAT_ART_FOLLOWS )
+	switch( getStat() )
 	{
-            retrievingFailed( msgId, client.lastStat );
+	case STAT_ART_FOLLOWS:
+	    res = retrieveAndStoreArt( msgId, ++(*artcnt), artmax );
+	    break;
+
+	case STAT_PROGRAM_FAULT:
 	    res = FALSE;
+	    /* Fall through */
+
+	default:
+            retrievingFailed( msgId, client.lastStat );
+	    break;
 	}
-        else
-	    res = retrieveAndStoreArt( msgId, ++(*artcnt), artmax );
     }
     del_DynStr( s );
     Lock_openDatabases();