Skip to content

Commit a160453

Browse files
mdouchametan-ucw
authored andcommitted
Unify error handling in include/tst_safe_posix_ipc.h
- Properly format caller file:line location Signed-off-by: Martin Doucha <[email protected]> Reviewed-by: Cyril Hrubis <[email protected]>
1 parent 7e0c9ad commit a160453

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

include/tst_safe_posix_ipc.h

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,11 @@ static inline int safe_mq_open(const char *file, const int lineno,
3636
va_end(ap);
3737

3838
rval = mq_open(pathname, oflags, mode, attr);
39+
3940
if (rval == -1) {
40-
tst_brk(TBROK | TERRNO, "%s:%d: mq_open(%s,%d,0%o,%p) failed",
41-
file, lineno, pathname, oflags, mode, attr);
41+
tst_brk_(file, lineno, TBROK | TERRNO,
42+
"mq_open(%s,%d,%04o,%p) failed", pathname, oflags,
43+
mode, attr);
4244
}
4345

4446
return rval;

0 commit comments

Comments
 (0)