mirror of
https://github.com/kdave/btrfs-progs
synced 2024-12-26 16:12:34 +00:00
btrfs-progs: print value when assertion fails
Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
db64e0a636
commit
9adce1abe4
@ -85,11 +85,11 @@ static inline void assert_trace(const char *assertion, const char *filename,
|
|||||||
if (val)
|
if (val)
|
||||||
return;
|
return;
|
||||||
if (assertion)
|
if (assertion)
|
||||||
fprintf(stderr, "%s:%d: %s: Assertion `%s` failed.\n",
|
fprintf(stderr, "%s:%d: %s: Assertion `%s` failed, value %d\n",
|
||||||
filename, line, func, assertion);
|
filename, line, func, assertion, val);
|
||||||
else
|
else
|
||||||
fprintf(stderr, "%s:%d: %s: Assertion failed.\n", filename,
|
fprintf(stderr, "%s:%d: %s: Assertion failed, value %d.\n",
|
||||||
line, func);
|
filename, line, func, val);
|
||||||
print_trace();
|
print_trace();
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user