[Snort-devel] patch in mstring.c

maruk maruk64 at ...224...
Wed Jun 27 14:59:01 EDT 2001


Hi,

here a little patch for mstring.c. As I don't know who is in charge of this 
file (I assume everyone :-) ) I send this patch to the devel-list:

--- /home/compile/ws/snort/mstring.c    Tue Jan  2 08:06:00 2001
+++ mstring.c   Wed Jun 27 18:57:07 2001
@@ -253,7 +253,10 @@
         retstr[curr_str] = (char *) malloc((sizeof(char) * len) + 1);
 
         if(retstr[curr_str] == NULL)
+        {
             printf("Got NULL back from substr malloc\n");
+            exit(1);
+        }
 
         memcpy(retstr[curr_str], (idx - len), len);
         retstr[curr_str][len] = 0;  

Bye 
Maruk
-- 
DUNLAP's Laws of physics:
 1. Fact is solidified opinion!
 2. Facts may weaken under extreme
    heat and pressure!
 3. Truth is elastic!





More information about the Snort-devel mailing list