Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=fvbe.git;a=commitdiff;h=436c428fc6a70d8055addb4b0e290c16f6c4f8a3

commit 436c428fc6a70d8055addb4b0e290c16f6c4f8a3
Author: James Buren <[email protected]>
Date:   Mon Apr 28 08:43:44 2014 -0500

replace casts to void with GCC attribute unused.

diff --git a/src-new/ui.cpp b/src-new/ui.cpp
index 7ea68b6..6a78c64 100644
--- a/src-new/ui.cpp
+++ b/src-new/ui.cpp
@@ -75,12 +75,8 @@ bool UI::setSignalInterrupt(int sig, bool interrupt)
return true;
}

-int UI::main(int argc, char **argv)
+int UI::main(__attribute__((unused)) int argc, __attribute__((unused)) char 
**argv)
{
-       // The arguments are never used here.
-       (void) argc;
-       (void) argv;
-
return EXIT_SUCCESS;
}
// UI Class End
diff --git a/src-new/ui_newt.cpp b/src-new/ui_newt.cpp
index ff3a40b..ef6ae29 100644
--- a/src-new/ui_newt.cpp
+++ b/src-new/ui_newt.cpp
@@ -5,14 +5,10 @@
#include "main.hpp"
#include "ui_newt.hpp"

-int UINewt::main(int argc, char **argv)
+int UINewt::main(__attribute__((unused)) int argc, __attribute__((unused)) 
char **argv)
{
int code = EXIT_FAILURE;

-       // We do not use the arguments in this UI.
-       (void) argc;
-       (void) argv;
-
// Check that the standard file streams are connected to a TTY.
if(!checkTTY(STDIN_FILENO) || !checkTTY(STDOUT_FILENO) || 
!checkTTY(STDERR_FILENO))
{
_______________________________________________
Frugalware-git mailing list
[email protected]
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to