diff -Naur snort-2.3.3/src/log.c snort-2.3.3-patched/src/log.c
--- snort-2.3.3/src/log.c	2004-12-09 17:38:46.000000000 +0000
+++ snort-2.3.3-patched/src/log.c	2005-09-13 13:42:52.000000000 +0000
@@ -1478,8 +1478,11 @@
                 {
                     for(j = 0; j < p->ip_options[i].len; j++)
                     {
-                        fprintf(fp, "%02X", p->ip_options[i].data[j]);
-                        
+			if (p->ip_options[i].data)    
+                        	fprintf(fp, "%02X", p->ip_options[i].data[j]);
+			else
+				fprintf(fp, "%02X", 0);
+			
                         if((j % 2) == 0)
                             fprintf(fp, " ");
                     }
@@ -1522,8 +1525,9 @@
             case TCPOPT_MAXSEG:
                 bzero((char *) tmp, 5);
                 fwrite("MSS: ", 5, 1, fp);
-                memcpy(tmp, p->tcp_options[i].data, 2);
-                fprintf(fp, "%u ", EXTRACT_16BITS(tmp));
+		if (p->tcp_options[i].data)
+			memcpy(tmp, p->tcp_options[i].data, 2);
+		fprintf(fp, "%u ", EXTRACT_16BITS(tmp));
                 break;
 
             case TCPOPT_EOL:
@@ -1535,16 +1539,21 @@
                 break;
 
             case TCPOPT_WSCALE:
-                fprintf(fp, "WS: %u ", p->tcp_options[i].data[0]);
-                break;
+		if (p->tcp_options[i].data)
+			fprintf(fp, "WS: %u ", p->tcp_options[i].data[0]);
+		else
+			fprintf(fp, "WS: %u ", 0);
+		break;
 
             case TCPOPT_SACK:
                 bzero((char *) tmp, 5);
-                memcpy(tmp, p->tcp_options[i].data, 2);
-                fprintf(fp, "Sack: %u@", EXTRACT_16BITS(tmp));
+		if (p->tcp_options[i].data)
+	                memcpy(tmp, p->tcp_options[i].data, 2);
+		fprintf(fp, "Sack: %u@", EXTRACT_16BITS(tmp));
                 bzero((char *) tmp, 5);
-                memcpy(tmp, (p->tcp_options[i].data) + 2, 2);
-                fprintf(fp, "%u ", EXTRACT_16BITS(tmp));
+		if (p->tcp_options[i].data)
+			memcpy(tmp, (p->tcp_options[i].data) + 2, 2);
+		fprintf(fp, "%u ", EXTRACT_16BITS(tmp));
                 break;
 
             case TCPOPT_SACKOK:
@@ -1553,40 +1562,47 @@
 
             case TCPOPT_ECHO:
                 bzero((char *) tmp, 5);
-                memcpy(tmp, p->tcp_options[i].data, 4);
+		if (p->tcp_options[i].data)
+			memcpy(tmp, p->tcp_options[i].data, 4);
                 fprintf(fp, "Echo: %u ", EXTRACT_32BITS(tmp));
                 break;
 
             case TCPOPT_ECHOREPLY:
                 bzero((char *) tmp, 5);
-                memcpy(tmp, p->tcp_options[i].data, 4);
+		if (p->tcp_options[i].data)
+			memcpy(tmp, p->tcp_options[i].data, 4);
                 fprintf(fp, "Echo Rep: %u ", EXTRACT_32BITS(tmp));
                 break;
 
             case TCPOPT_TIMESTAMP:
                 bzero((char *) tmp, 5);
-                memcpy(tmp, p->tcp_options[i].data, 4);
+		if (p->tcp_options[i].data)
+	                memcpy(tmp, p->tcp_options[i].data, 4);
                 fprintf(fp, "TS: %u ", EXTRACT_32BITS(tmp));
                 bzero((char *) tmp, 5);
-                memcpy(tmp, (p->tcp_options[i].data) + 4, 4);
+		if (p->tcp_options[i].data)
+	                memcpy(tmp, (p->tcp_options[i].data) + 4, 4);
                 fprintf(fp, "%u ", EXTRACT_32BITS(tmp));
                 break;
 
             case TCPOPT_CC:
                 bzero((char *) tmp, 5);
-                memcpy(tmp, p->tcp_options[i].data, 4);
+		if (p->tcp_options[i].data)
+			memcpy(tmp, p->tcp_options[i].data, 4);
                 fprintf(fp, "CC %u ", EXTRACT_32BITS(tmp));
                 break;
 
             case TCPOPT_CCNEW:
                 bzero((char *) tmp, 5);
-                memcpy(tmp, p->tcp_options[i].data, 4);
+		if (p->tcp_options[i].data)
+			memcpy(tmp, p->tcp_options[i].data, 4);
                 fprintf(fp, "CCNEW: %u ", EXTRACT_32BITS(tmp));
                 break;
 
             case TCPOPT_CCECHO:
                 bzero((char *) tmp, 5);
-                memcpy(tmp, p->tcp_options[i].data, 4);
+		if (p->tcp_options[i].data)
+			memcpy(tmp, p->tcp_options[i].data, 4);
                 fprintf(fp, "CCECHO: %u ", EXTRACT_32BITS(tmp));
                 break;
 
@@ -1598,8 +1614,10 @@
 
                     for(j = 0; j < p->tcp_options[i].len; j++)
                     {
-                        fprintf(fp, "%02X", p->tcp_options[i].data[j]);
-                        
+			if (p->tcp_options[i].data)    
+	                        fprintf(fp, "%02X", p->tcp_options[i].data[j]);
+        		else
+				fprintf(fp, "%02X", 0);		
                         if((j % 2) == 0)
                             fprintf(fp, " ");
                     }
