PERFORCE change 109213 for review

John Birrell jb at FreeBSD.org
Sat Nov 4 05:04:09 UTC 2006


http://perforce.freebsd.org/chv.cgi?CH=109213

Change 109213 by jb at jb_freebsd8 on 2006/11/04 05:03:28

	While debugging the new libelf for use with DTrace, I want
	to see where the errors are ocurring.

Affected files ...

.. //depot/projects/dtrace/src/lib/libelf/_libelf.h#12 edit

Differences ...

==== //depot/projects/dtrace/src/lib/libelf/_libelf.h#12 (text+ko) ====

@@ -30,6 +30,7 @@
 #define	__LIBELF_H_
 
 #include <sys/queue.h>
+#include <stdio.h>
 
 #ifndef	NULL
 #define NULL 	((void *) 0)
@@ -61,6 +62,7 @@
 #define	LIBELF_SET_ERROR(E, O) do {					\
 	LIBELF_PRIVATE(error) = ((ELF_E_##E & LIBELF_ELF_ERROR_MASK)|	\
 	    ((O) << LIBELF_OS_ERROR_SHIFT));				\
+	printf("Error %d in function %s line %d\n", ELF_E_##E, __FUNCTION__, __LINE__); \
 	} while (0)
 
 #define	LIBELF_ADJUST_AR_SIZE(S)	(((S) + 1U) & ~1U)


More information about the p4-projects mailing list