diff src/client.c @ 95:c3312022e657 noffle

[svn] Observe Supersedes: header
author bears
date Fri, 19 May 2000 16:16:50 +0100
parents 1fcdced0246e
children 38b0a1532a37
line wrap: on
line diff
--- a/src/client.c	Fri May 19 16:15:45 2000 +0100
+++ b/src/client.c	Fri May 19 16:16:50 2000 +0100
@@ -1,7 +1,7 @@
 /*
   client.c
 
-  $Id: client.c 100 2000-05-18 12:17:23Z bears $
+  $Id: client.c 114 2000-05-19 15:16:50Z bears $
 */
 
 #if HAVE_CONFIG_H
@@ -21,6 +21,7 @@
 #include <unistd.h>
 #include "configfile.h"
 #include "content.h"
+#include "control.h"
 #include "dynamicstring.h"
 #include "group.h"
 #include "itemlist.h"
@@ -970,7 +971,19 @@
     while ( getTxtLn( line, &err ) && ! err )
         DynStr_appLn( s, line );
     if ( ! err )
-        Db_storeArt( msgId, DynStr_str( s ) );
+    {
+	const char *txt;
+
+	txt = DynStr_str( s );
+        err = ! Db_storeArt( msgId, txt );
+	if ( ! err )
+	{
+	    Str supersedeId;
+
+	    if ( Prt_searchHeader( txt, "Supersedes", supersedeId ) )
+		 Ctrl_cancel( supersedeId );
+	}
+    }
     else
         retrievingFailed( msgId, "Connection broke down" );
     del_DynStr( s );