Missing pragma pack causes gcov crash

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hey there,

inside the source file 'pjlib-util\src\pjlib-util\pcap.c' there's a
#pragma pack(1)

But after the structure definitions, the pragma is not getting disabled any more.
This causes a segmentation fault when doing code coverage analysis with GCOV.

The following patch fixes the bug:

diff --git a/pjlib-util/src/pjlib-util/pcap.c b/pjlib-util/src/pjlib-util/pcap.c
index 0117a04..071b8ad 100644
--- a/pjlib-util/src/pjlib-util/pcap.c
+++ b/pjlib-util/src/pjlib-util/pcap.c
@@ -89,6 +89,7 @@ struct pj_pcap_file
     pj_pcap_hdr            hdr;
     pj_pcap_filter  filter;
 };
+#pragma pack()
 
 /* Init default filter */
 PJ_DEF(void) pj_pcap_filter_default(pj_pcap_filter *filter)



Regards,
Michael
_______________________________________________
Visit our blog: http://blog.pjsip.org

pjsip mailing list
pjsip@xxxxxxxxxxxxxxx
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org

[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux