[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] fix paxfatal usage
From: |
Matteo Croce |
Subject: |
[PATCH] fix paxfatal usage |
Date: |
Mon, 30 Sep 2024 15:51:04 +0200 |
From: Matteo Croce <teknoraver@meta.com>
Commit c4b3c2d7f90a ("Simplify paxusage API") in paxutil removed the
first argument in paxfatal macro, since it was always zero.
A code block in buffer.c was still passing three arguments, leading to
thie warning (or error with -Werror):
buffer.c: In function ‘_open_archive’:
../lib/system.h:150:18: error: too many arguments for format
[-Werror=format-extra-args]
150 | #define _(msgid) gettext (msgid)
| ^~~~~~~~~~~~~~~
buffer.c:727:21: note: in expansion of macro ‘_’
727 | paxfatal (0, 0, _("Invalid value for record_size"));
| ^
Fix it by removing the spurious argument.
---
src/buffer.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/buffer.c b/src/buffer.c
index 48ae840f..570c8666 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -724,7 +724,7 @@ _open_archive (enum access_mode wanted_access)
bool backed_up_flag = false;
if (record_size == 0)
- paxfatal (0, 0, _("Invalid value for record_size"));
+ paxfatal (0, _("Invalid value for record_size"));
if (archive_names == 0)
paxfatal (0, _("No archive name given"));
--
2.46.2
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [PATCH] fix paxfatal usage,
Matteo Croce <=