aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSeebs <seebs@seebs.net>2018-01-16 19:17:19 -0600
committerSeebs <seebs@seebs.net>2018-01-16 19:26:18 -0600
commit4a8a71f1e78860262e189ba36a19afca956b81c2 (patch)
tree0e7bde799ef7f1b5b31a809097eae64b55100b04
parentfffb4fb3be46911e8725dae229f8a4a07ecd9ba8 (diff)
downloadpseudo-4a8a71f1e78860262e189ba36a19afca956b81c2.tar.gz
pseudo-4a8a71f1e78860262e189ba36a19afca956b81c2.tar.bz2
pseudo-4a8a71f1e78860262e189ba36a19afca956b81c2.zip
Drop diagnostic for missing "real" functions
It turns out that these diagnostics can be spurious now on some hosts, also that they've probably been wrong forever; for instance, on some Linux, there's not a real "mknod" function and probably never was, so reporting this error is pointless. Signed-off-by: Seebs <seebs@seebs.net>
-rw-r--r--ChangeLog.txt2
-rw-r--r--pseudo_wrappers.c20
2 files changed, 6 insertions, 16 deletions
diff --git a/ChangeLog.txt b/ChangeLog.txt
index 033fdcf..165faa8 100644
--- a/ChangeLog.txt
+++ b/ChangeLog.txt
@@ -3,6 +3,8 @@
it's actually probably right.
* (<zboszor@pr.hu>) handle extremely long group names
in getgrnam and similar functions.
+ * (seebs) drop the diagnostic for a missing "real" function
+ as it turns out to be counterproductive at best.
2017-12-22:
* (seebs) handle the pathological case of LINKAT with
diff --git a/pseudo_wrappers.c b/pseudo_wrappers.c
index 12bc541..ad3a8c0 100644
--- a/pseudo_wrappers.c
+++ b/pseudo_wrappers.c
@@ -131,7 +131,6 @@ static void
pseudo_init_one_wrapper(pseudo_function *func) {
int (*f)(void) = (int (*)(void)) NULL;
- char *e;
if (*func->real != NULL) {
/* already initialized */
return;
@@ -147,22 +146,11 @@ pseudo_init_one_wrapper(pseudo_function *func) {
f = dlsym(RTLD_NEXT, func->name);
if (f) {
*func->real = f;
- } else {
-#ifdef PSEUDO_NO_REAL_AT_FUNCTIONS
- char *s = func->name;
- s += strlen(s) - 2;
- /* *at() don't have to exist */
- if (!strcmp(s, "at")) {
- return;
- }
-#endif
- e = dlerror();
- if (e != NULL) {
- pseudo_diag("No real function for %s: %s\n", func->name, e);
- } else {
- pseudo_diag("No real function for %s, but dlerror NULL.\n", func->name);
- }
}
+ /* it turns out that in some cases, we get apparently-harmless
+ * errors if a function is missing, and that printing output
+ * for these seems unhelpful. so we no longer do that.
+ */
}
void