rfminelli / lusca-cache

Automatically exported from code.google.com/p/lusca-cache
GNU General Public License v2.0
0 stars 0 forks source link

segmentation violation #4

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
FATAL: Received Segment Violation...dying.
2009/02/11 01:50:53| storeDirWriteCleanLogs: Starting...
2009/02/11 01:50:53| WARNING: Closing open FD   15
2009/02/11 01:50:53| commSetEvents: epoll_ctl(EPOLL_CTL_DEL): failed on
fd=15: (1) Operation not permitted
2009/02/11 01:50:53| WARNING: Closing open FD   16
2009/02/11 01:50:53| commSetEvents: epoll_ctl(EPOLL_CTL_DEL): failed on
fd=16: (1) Operation not permitted

(gdb) bt
#0  0x000000368e830155 in raise () from /lib64/libc.so.6
#1  0x000000368e831bf0 in abort () from /lib64/libc.so.6
#2  0x000000000046ddae in death (sig=<value optimized out>) at tools.c:326
#3  <signal handler called>
#4  0x000000000043fb03 in httpReadReply (fd=61, data=<value optimized out>)
at http.c:1233
#5  0x00000000004a0259 in comm_select (msec=<value optimized out>) at
comm_generic.c:264
#6  0x000000000044775b in main (argc=<value optimized out>,
argv=0x7fffa2676448) at main.c:933

(gdb) frame 4
#4  0x000000000043fb03 in httpReadReply (fd=61, data=<value optimized out>)
at http.c:1233
1233        httpAppendBody(httpState, buf_buf(httpState->read_buf) + po + done,

(gdb) print *httpState
$1 = {entry = 0xa2bd00, request = 0x1a40ae30, read_buf = 0x0,
reply_hdr_state = 2, peer = 0x0, eof = 0, orig_request = 0x1a40ae30, fd =
61, flags = {proxying = 0,
    keepalive = 1, only_if_cached = 0, keepalive_broken = 0, abuse_detected
= 0, request_sent = 1, front_end_https = 0, originpeer = 0, chunked = 0,
trailer = 0, http11 = 0},
  fwd = 0x1a3f7e48, body_buf = 0x0, body_buf_sz = 0, chunk_size = -1,
chunkhdr = {size = 0, len = 0, buf = 0x0}}

(gdb) print httpState->read_buf
$2 = (buf_t *) 0x0

(gdb) frame 5
#5  0x00000000004a0259 in comm_select (msec=<value optimized out>) at
comm_generic.c:264
264                     hdl(fd, hdl_data);
(gdb) print hdl_data
$5 = (void *) 0x1a3c9798

(gdb) frame 6
#6  0x000000000044775b in main (argc=<value optimized out>,
argv=0x7fffa2676448) at main.c:933
933             switch (iapp_runonce(loop_delay)) {
(gdb) print loop_delay
$6 = 440178584

Original issue reported on code.google.com by ajcor...@gmail.com on 11 Feb 2009 at 4:15

GoogleCodeExporter commented 8 years ago
Here, try this:

Index: http.c
===================================================================
--- http.c      (revision 13799)
+++ http.c      (working copy)
@@ -1230,10 +1230,12 @@10 22:59:45 on ttyp5
     assert(httpState->reply_hdr_state == 2);
     /* lock the httpState; it may be freed by a call to httpAppendBody */
     cbdataLock(httpState); ls
-    httpAppendBody(httpState, buf_buf(httpState->read_buf) + po + done,
-      buf_len(httpState->read_buf) - po - done, buffer_filled);
-    if (cbdataValid(httpState))CA_HEAD/src adrian$ vi http.c 
-       httpState->read_buf = buf_deref(httpState->read_buf);
+    if (httpState->read_buf) {
+        httpAppendBody(httpState, buf_buf(httpState->read_buf) + po + done,
+          buf_len(httpState->read_buf) - po - done, buffer_filled);
+        if (cbdataValid(httpState))
+            httpState->read_buf = buf_deref(httpState->read_buf);
+    }
     cbdataUnlock(httpState);
     /* httpState may be cleared here */

Original comment by adrian.c...@gmail.com on 11 Feb 2009 at 4:18

GoogleCodeExporter commented 8 years ago
solved.. running stable since patched !!

Original comment by ajcor...@gmail.com on 11 Feb 2009 at 2:05

GoogleCodeExporter commented 8 years ago
fixed in rl13809

Original comment by ajcor...@gmail.com on 11 Feb 2009 at 9:46

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Fixed!

Original comment by adrian.c...@gmail.com on 9 Jul 2009 at 6:16