[syslinux:elflink] xfs: Improve error and debug printing

syslinux-bot for Paulo Alcantara pcacjr at zytor.com
Thu Jan 24 09:45:05 PST 2013


Commit-ID:  51e6a071378786c799a23fb758534cb8ac959a25
Gitweb:     http://www.syslinux.org/commit/51e6a071378786c799a23fb758534cb8ac959a25
Author:     Paulo Alcantara <pcacjr at zytor.com>
AuthorDate: Mon, 21 Jan 2013 16:03:00 -0200
Committer:  Paulo Alcantara <pcacjr at zytor.com>
CommitDate: Mon, 21 Jan 2013 16:03:00 -0200

xfs: Improve error and debug printing

Signed-off-by: Paulo Alcantara <pcacjr at zytor.com>

---
 core/fs/xfs/xfs.h | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/core/fs/xfs/xfs.h b/core/fs/xfs/xfs.h
index da57221..49c9302 100644
--- a/core/fs/xfs/xfs.h
+++ b/core/fs/xfs/xfs.h
@@ -31,10 +31,14 @@
 #include "xfs_ag.h"
 
 #define xfs_error(fmt, args...) \
-    printf("xfs: " fmt "\n", ## args);
+    ({ \
+       printf("%s%s: xfs: [ERROR] " fmt "\n", __func__, __LINE__, ## args); \
+    })
 
 #define xfs_debug(fmt, args...) \
-    dprintf("%s: " fmt "\n", __func__, ## args);
+    ({ \
+       dprintf("%s%s: xfs: [DEBUG] " fmt "\n", __func__, __LINE__, ## args); \
+    })
 
 struct xfs_fs_info;
 


More information about the Syslinux-commits mailing list