]> jfr.im git - irc/blitzed-org/libopm.git/commitdiff
Fixed a bug where a freed conn was possibly used in the scan end code
authorstrtok <redacted>
Wed, 6 Nov 2002 07:12:20 +0000 (07:12 +0000)
committerstrtok <redacted>
Wed, 6 Nov 2002 07:12:20 +0000 (07:12 +0000)
src/libopm.c
src/malloc.c
src/test.c

index d8003ab76625dbba9eb1d7dbb91b7ab6202783df..7e21ea21f83b33c0f1108cc2d23ac5abf8e376f6 100644 (file)
@@ -881,7 +881,7 @@ static void libopm_check_closed(OPM_T *scanner)
          scan from the scanner, and free it up */
       if(LIST_SIZE(scan->connections) == 0)
       {
-         libopm_do_callback(scanner, libopm_setup_remote(scan->remote, conn), OPM_CALLBACK_END, 0);
+         libopm_do_callback(scanner, scan->remote, OPM_CALLBACK_END, 0);
 
          libopm_list_remove(scanner->scans, node1);
          libopm_scan_free(scan);
index 849793f6b118dd78cf152c4399947ade93f83234..736adaced60f80fbd99198ac4b835a35acda5b6c 100644 (file)
@@ -29,6 +29,7 @@
 
 RCSID("$Id$");
 
+
 /* MyMalloc
  *  
  *   A wrapper function for malloc(), for catching memory issues
@@ -52,7 +53,6 @@ void *libopm_MyMalloc(size_t bytes)
 
 
 
-
 /*  MyFree
  *
  *  Free memory allocated with MyMalloc
index b5b4bf44b7af9c570cacbd6f93a3cfdc843fe934..de39e5a51929299c1b21e18f12ab8bee41f96ffe 100644 (file)
@@ -112,7 +112,7 @@ int main(int argc, char **argv)
       opm_cycle(scanner);
    
    opm_free(scanner);
-   
+   while(1); 
    return 0; 
 }