Commit 9899e690 authored by Davi Arnaut's avatar Davi Arnaut

Bug#45288: pb2 returns a lot of compilation warnings on linux

Fix compiler warnings.

mysys/stacktrace.c:
  Tag unused parameters.
sql/sql_lex.cc:
  Variable becomes unused in non-debug builds. Also, no need to
  assert the obvious.
parent 655d913b
......@@ -86,7 +86,9 @@ void my_print_stacktrace(uchar* stack_bottom __attribute__((unused)),
#if BACKTRACE_DEMANGLE
char __attribute__ ((weak)) *my_demangle(const char *mangled_name, int *status)
char __attribute__ ((weak)) *
my_demangle(const char *mangled_name __attribute__((unused)),
int *status __attribute__((unused)))
{
return NULL;
}
......
......@@ -1303,8 +1303,6 @@ int MYSQLlex(void *arg, void *yythd)
}
else
{
const char* version_mark= lip->get_ptr() - 1;
DBUG_ASSERT(*version_mark == '!');
/*
Patch and skip the conditional comment to avoid it
being propagated infinitely (eg. to a slave).
......@@ -1313,7 +1311,6 @@ int MYSQLlex(void *arg, void *yythd)
comment_closed= ! consume_comment(lip, 1);
if (! comment_closed)
{
DBUG_ASSERT(pcom == version_mark);
*pcom= '!';
}
/* version allowed to have one level of comment inside. */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment