[git commit] appletlib: fix set-but-unused warning

Mike Frysinger vapier at gentoo.org
Fri Jan 31 05:29:47 UTC 2014


commit: http://git.busybox.net/busybox/commit/?id=f1999b5a9d2788cdc120b1ee2ab1de18e95b38f2
branch: http://git.busybox.net/busybox/commit/?id=refs/heads/master

When you build with FEATURE_INSTALLER disabled, you get a build
warning like so:

libbb/appletlib.c: In function 'busybox_main':
libbb/appletlib.c:691:7: warning: variable 'use_symbolic_links' set but
                                  not used [-Wunused-but-set-variable]
   int use_symbolic_links;
       ^

Signed-off-by: Mike Frysinger <vapier at gentoo.org>
---
 libbb/appletlib.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/libbb/appletlib.c b/libbb/appletlib.c
index 8f3a8a1..f7c416e 100644
--- a/libbb/appletlib.c
+++ b/libbb/appletlib.c
@@ -606,7 +606,11 @@ static void install_links(const char *busybox, int use_symbolic_links,
 	}
 }
 # else
-#  define install_links(x,y,z) ((void)0)
+static void install_links(const char *busybox UNUSED_PARAM,
+		int use_symbolic_links UNUSED_PARAM,
+		char *custom_install_dir UNUSED_PARAM)
+{
+}
 # endif
 
 /* If we were called as "busybox..." */


More information about the busybox-cvs mailing list