[Xastir-Dev] "Reindex ALL Maps" SIG-11 fix

Henk de Groot henk.de.groot at hetnet.nl
Sun Aug 17 14:43:18 EDT 2003


Hello,

I just installed the Xastir CVS version with the changed paths (yes, I'm 
not very active at the moment...). One of the instructions in the UPDATE 
document is to reindex the maps. On my system this resulted in a SIG-11 
fault. Here is the patch to maps.c to fix it. It is trivial, the assignment 
"current = current->next;" is at the wrong place (fault occured at "if 
(current->XmStringPtr != NULL) {" with "current" == NULL).

------------------------------------------------------------------------
--- xastir/src/maps.c.orig	Sun Aug 17 15:29:30 2003
+++ xastir/src/maps.c	Sun Aug 17 20:37:49 2003
@@ -2812,14 +2812,14 @@

      current = index_list_head;

      while (current != NULL) {
          temp = current;
-        current = current->next;
          if (current->XmStringPtr != NULL) {
              XmStringFree(current->XmStringPtr);
          }
+        current = current->next;
          free(temp);
      }

      index_list_head = NULL;
  }
------------------------------------------------------------------------

Kind regards,

Henk.



More information about the Xastir-dev mailing list