* [PATCH] sys-utils: lscpu segfaults when built with -fsanitize=address
@ 2015-05-30 18:51 Cristian Rodríguez
2015-06-02 10:53 ` Karel Zak
0 siblings, 1 reply; 2+ messages in thread
From: Cristian Rodríguez @ 2015-05-30 18:51 UTC (permalink / raw)
To: util-linux; +Cc: Cristian Rodríguez
This is expected and a false positive, exclude the vmware detection
trick when __SANITIZE_ADDRESS__ is defined.
---
sys-utils/lscpu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sys-utils/lscpu.c b/sys-utils/lscpu.c
index b36d1da..f695a32 100644
--- a/sys-utils/lscpu.c
+++ b/sys-utils/lscpu.c
@@ -34,7 +34,7 @@
#include <sys/types.h>
#include <sys/stat.h>
-#if defined(__x86_64__) || defined(__i386__)
+#if (defined(__x86_64__) || defined(__i386__)) && !defined(__SANITIZE_ADDRESS__)
# define INCLUDE_VMWARE_BDOOR
#endif
--
2.4.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] sys-utils: lscpu segfaults when built with -fsanitize=address
2015-05-30 18:51 [PATCH] sys-utils: lscpu segfaults when built with -fsanitize=address Cristian Rodríguez
@ 2015-06-02 10:53 ` Karel Zak
0 siblings, 0 replies; 2+ messages in thread
From: Karel Zak @ 2015-06-02 10:53 UTC (permalink / raw)
To: Cristian Rodríguez; +Cc: util-linux
On Sat, May 30, 2015 at 03:51:41PM -0300, Cristian Rodríguez wrote:
> This is expected and a false positive, exclude the vmware detection
> trick when __SANITIZE_ADDRESS__ is defined.
> ---
> sys-utils/lscpu.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, but I have added a preprocessor warning when the detection
is disabled by -fsanitize=address. Thanks!
Karel
--
Karel Zak <kzak@redhat.com>
http://karelzak.blogspot.com
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-06-02 10:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-30 18:51 [PATCH] sys-utils: lscpu segfaults when built with -fsanitize=address Cristian Rodríguez
2015-06-02 10:53 ` Karel Zak
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox