diff options
author | Matthieu Herrb <matthieu@cvs.openbsd.org> | 2022-06-25 21:12:42 +0000 |
---|---|---|
committer | Matthieu Herrb <matthieu@cvs.openbsd.org> | 2022-06-25 21:12:42 +0000 |
commit | 3f4f9a6e81495fd4702f4dfe5e4c1d5b9df84e04 (patch) | |
tree | 82e199144d569910b7a2531a0f95170b9e8c3b17 | |
parent | 448eecd0911ea38a0aac86e868fb7ca10db2670c (diff) |
Get rid of remaining compiler warnings on OpenBSD
-rw-r--r-- | app/xclock/Clock.c | 4 | ||||
-rw-r--r-- | app/xclock/xclock.c | 3 |
2 files changed, 4 insertions, 3 deletions
diff --git a/app/xclock/Clock.c b/app/xclock/Clock.c index 6611fd2be..bb422031c 100644 --- a/app/xclock/Clock.c +++ b/app/xclock/Clock.c @@ -831,7 +831,9 @@ RenderTextBounds(ClockWidget w, char *str, int off, int len, else #endif { - fallback: +#if defined(HAVE_ICONV) && defined(HAVE_NL_LANGINFO) + fallback: +#endif XftTextExtents8(XtDisplay(w), w->clock.face, (FcChar8 *) str, off, &head); XftTextExtents8(XtDisplay(w), w->clock.face, (FcChar8 *) str + off, diff --git a/app/xclock/xclock.c b/app/xclock/xclock.c index 7ee88b63e..c62750d54 100644 --- a/app/xclock/xclock.c +++ b/app/xclock/xclock.c @@ -231,10 +231,9 @@ main(int argc, char *argv[]) { /* force reading of XErrorDB into memory to avoid adding "rpath" to pledge below */ - int r; char buf[1]; - r = XGetErrorDatabaseText(XtDisplay(toplevel), "XProtoError", "0", "", buf, 1); + (void)XGetErrorDatabaseText(XtDisplay(toplevel), "XProtoError", "0", "", buf, 1); } if (pledge("stdio", NULL) == -1) err(1, "pledge"); |