Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 598007 Details for
Bug 839605
event message corrupted (may be because of valgrind: socketcall.sendto(msg) points to unaddressable byte(s))
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Patch to ensure problem is really in libqb event
problem.patch (text/plain), 4.47 KB, created by
Jan Friesse
on 2012-07-13 08:26:03 UTC
(
hide
)
Description:
Patch to ensure problem is really in libqb event
Filename:
MIME Type:
Creator:
Jan Friesse
Created:
2012-07-13 08:26:03 UTC
Size:
4.47 KB
patch
obsolete
>diff --git a/cts/agents/cpg_test_agent.c b/cts/agents/cpg_test_agent.c >index f9e0350..50a620e 100644 >--- a/cts/agents/cpg_test_agent.c >+++ b/cts/agents/cpg_test_agent.c >@@ -164,6 +164,9 @@ static void delivery_callback ( > } > if (msg_len != msg_pt->size) { > status = MSG_SIZE_ERR; >+ >+ fprintf(stderr," ERR: nid = %u, pid = %u, seq = %u, size = (%zu 0x%zx) msg_len = %zu", >+ msg_pt->nodeid, msg_pt->pid, msg_pt->seq, msg_pt->size, msg_pt->size, msg_len); > } > PK11_DigestBegin(sha1_context); > PK11_DigestOp(sha1_context, msg_pt->payload, (msg_pt->size - sizeof (msg_t))); >diff --git a/exec/cpg.c b/exec/cpg.c >index 47743a5..904e905 100644 >--- a/exec/cpg.c >+++ b/exec/cpg.c >@@ -1318,6 +1318,15 @@ static void message_handler_req_exec_cpg_joinlist ( > } > } > >+typedef struct { >+uint32_t nodeid; >+pid_t pid; >+unsigned char sha1[20]; >+uint32_t seq; >+size_t size; >+unsigned char payload[0]; >+} msg_t; >+ > static void message_handler_req_exec_cpg_mcast ( > const void *message, > unsigned int nodeid) >@@ -1329,6 +1338,7 @@ static void message_handler_req_exec_cpg_mcast ( > struct cpg_pd *cpd; > struct iovec iovec[2]; > int known_node = 0; >+ msg_t *msg_pt; > > res_lib_cpg_mcast.header.id = MESSAGE_RES_CPG_DELIVER_CALLBACK; > res_lib_cpg_mcast.header.size = sizeof(res_lib_cpg_mcast) + msglen; >@@ -1371,6 +1381,11 @@ static void message_handler_req_exec_cpg_mcast ( > return ; > } > >+ msg_pt = (msg_t *)iovec[1].iov_base; >+ if (msg_pt->size > 102400) { >+ fprintf(stderr," ERR: nid = %u, pid = %u, seq = %u, size = (%zu 0x%zx) msg_len = %zu\n", >+ msg_pt->nodeid, msg_pt->pid, msg_pt->seq, msg_pt->size, msg_pt->size, iovec[1].iov_len); >+ } > api->ipc_dispatch_iov_send (cpd->conn, iovec, 2); > } > } >diff --git a/exec/ipc_glue.c b/exec/ipc_glue.c >index a3f11c7..cd0a401 100644 >--- a/exec/ipc_glue.c >+++ b/exec/ipc_glue.c >@@ -53,6 +53,8 @@ > #include <corosync/totem/totempg.h> > #include <corosync/logsys.h> > #include <corosync/icmap.h> >+#include <corosync/cpg.h> >+#include <corosync/ipc_cpg.h> > > #include "sync.h" > #include "timer.h" >@@ -454,6 +456,15 @@ int cs_ipcs_response_send(void *conn, const void *msg, size_t mlen) > return rc; > } > >+typedef struct { >+uint32_t nodeid; >+pid_t pid; >+unsigned char sha1[20]; >+uint32_t seq; >+size_t size; >+unsigned char payload[0]; >+} msg_t; >+ > static void outq_flush (void *data) > { > qb_ipcs_connection_t *conn = data; >@@ -461,6 +472,8 @@ static void outq_flush (void *data) > struct outq_item *outq_item; > int32_t rc; > struct cs_ipcs_conn_context *context = qb_ipcs_context_get(conn); >+ struct res_lib_cpg_deliver_callback *res_lib_cpg_mcast; >+ msg_t *msg_pt; > > for (list = context->outq_head.next; > list != &context->outq_head; list = list_next) { >@@ -468,6 +481,15 @@ static void outq_flush (void *data) > list_next = list->next; > outq_item = list_entry (list, struct outq_item, list); > >+ res_lib_cpg_mcast = outq_item->msg; >+ if (res_lib_cpg_mcast->header.id == MESSAGE_RES_CPG_DELIVER_CALLBACK) { >+ msg_pt = (msg_t *)((char *)outq_item->msg + sizeof(*res_lib_cpg_mcast)); >+ if (msg_pt->size > 102400) { >+ fprintf(stderr," ERR2: nid = %u, pid = %u, seq = %u, size = (%zu 0x%zx) msg_len = %u\n", >+ msg_pt->nodeid, msg_pt->pid, msg_pt->seq, msg_pt->size, msg_pt->size, res_lib_cpg_mcast->msglen); >+ } >+ } >+ > rc = qb_ipcs_event_send(conn, outq_item->msg, outq_item->mlen); > if (rc < 0 && rc != -EAGAIN) { > errno = -rc; >@@ -505,6 +527,8 @@ static void msg_send_or_queue(qb_ipcs_connection_t *conn, const struct iovec *io > struct outq_item *outq_item; > char *write_buf = 0; > struct cs_ipcs_conn_context *context = qb_ipcs_context_get(conn); >+ struct res_lib_cpg_deliver_callback *res_lib_cpg_mcast; >+ msg_t *msg_pt; > > for (i = 0; i < iov_len; i++) { > bytes_msg += iov[i].iov_len; >@@ -512,6 +536,17 @@ static void msg_send_or_queue(qb_ipcs_connection_t *conn, const struct iovec *io > > if (!context->queuing) { > assert(list_empty (&context->outq_head)); >+ if (iov_len == 2 && iov[0].iov_len == sizeof (*res_lib_cpg_mcast)) { >+ res_lib_cpg_mcast = iov[0].iov_base; >+ if (res_lib_cpg_mcast->header.id == MESSAGE_RES_CPG_DELIVER_CALLBACK) { >+ msg_pt = (msg_t *)iov[1].iov_base; >+ if (msg_pt->size > 102400) { >+ fprintf(stderr," ERR1: nid = %u, pid = %u, seq = %u, size = (%zu 0x%zx) msg_len = %zu\n", >+ msg_pt->nodeid, msg_pt->pid, msg_pt->seq, msg_pt->size, msg_pt->size, iov[1].iov_len); >+ } >+ } >+ } >+ > rc = qb_ipcs_event_sendv(conn, iov, iov_len); > if (rc == bytes_msg) { > context->sent++;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 839605
: 598007