Don't specify g++ version; add some consts to fix warnings with newer g++.

This commit is contained in:
ehouse 2008-05-21 03:49:11 +00:00
parent 6280129788
commit 4c191e0755
2 changed files with 4 additions and 4 deletions

View file

@ -15,7 +15,7 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
CXX = g++-4.1
CXX = g++
CC=$(CXX)
SRC = xwrelay.cpp \
cref.cpp \

View file

@ -76,7 +76,7 @@ static bool cmd_uptime( int socket, const char** args );
static bool cmd_crash( int socket, const char** args );
static int
match( string* cmd, char * const* first, int incr, int count )
match( string* cmd, const char * const* first, int incr, int count )
{
int cmdlen = cmd->length();
int nFound = 0;
@ -226,7 +226,7 @@ cmd_get( int socket, const char** args )
bool needsHelp = true;
string attr(args[1]);
char* const attrs[] = { "help", "listeners", "loglevel" };
const char* const attrs[] = { "help", "listeners", "loglevel" };
int index = match( &attr, attrs, sizeof(attrs[0]),
sizeof(attrs)/sizeof(attrs[0]));
@ -280,7 +280,7 @@ static bool
cmd_set( int socket, const char** args )
{
const char* val = args[2];
char* const attrs[] = { "help", "listeners", "loglevel" };
const char* const attrs[] = { "help", "listeners", "loglevel" };
string attr(args[1]);
int index = match( &attr, attrs, sizeof(attrs[0]),
sizeof(attrs)/sizeof(attrs[0]));