1
0
Fork 0

Adding upstream version 2.41.

Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
This commit is contained in:
Daniel Baumann 2025-06-21 11:26:35 +02:00
parent 9586bb3c92
commit c36e531662
Signed by: daniel.baumann
GPG key ID: BCC918A2ABD66424
3661 changed files with 2164106 additions and 0 deletions

23
include/fgetwc_or_err.h Normal file
View file

@ -0,0 +1,23 @@
#ifndef UTIL_LINUX_FGETWC_OR_ERR_H
#define UTIL_LINUX_FGETWC_OR_ERR_H
#include <stdio.h>
#include <wchar.h>
#include <errno.h>
#include "widechar.h"
#include "c.h"
#include "nls.h"
static inline wint_t fgetwc_or_err(FILE *stream) {
wint_t ret;
errno = 0;
ret = fgetwc(stream);
if (ret == WEOF && errno != 0)
err(EXIT_FAILURE, _("fgetwc() failed"));
return ret;
}
#endif /* _FGETWC_OR_ERR_H */