mirror of
https://github.com/MariaDB/server.git
synced 2026-05-13 18:40:48 +02:00
MDEV-36542: remove _lint macro which is unused
Attribute noreturn functions don't need a return afterwards. aria_pack was missing the noreturn attribute on its my_end function.
This commit is contained in:
parent
0c80ddb519
commit
4f9221ae88
12 changed files with 10 additions and 31 deletions
|
|
@ -1387,9 +1387,7 @@ int main(int argc,char *argv[])
|
|||
if (opt_outfile)
|
||||
end_tee();
|
||||
mysql_end(0);
|
||||
#ifndef _lint
|
||||
DBUG_RETURN(0); // Keep compiler happy
|
||||
#endif
|
||||
DBUG_RETURN(0);
|
||||
}
|
||||
|
||||
sig_handler mysql_end(int sig)
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@
|
|||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
#if !defined(DBUG_OFF) && !defined(_lint)
|
||||
#if !defined(DBUG_OFF)
|
||||
|
||||
struct _db_stack_frame_ {
|
||||
const char *func; /* function name of the previous stack frame */
|
||||
|
|
@ -210,7 +210,7 @@ extern void (*my_dbug_assert_failed)(const char *assert_expr, const char* file,
|
|||
#define DBUG_ASSERT(A) do { } while(0)
|
||||
#define IF_DBUG_ASSERT(A,B) B
|
||||
#endif /* DBUG_ASSERT_AS_PRINTF */
|
||||
#endif /* !defined(DBUG_OFF) && !defined(_lint) */
|
||||
#endif /* !defined(DBUG_OFF) */
|
||||
|
||||
#ifdef EXTRA_DEBUG
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -281,10 +281,6 @@ C_MODE_END
|
|||
#error "Please add -fno-exceptions to CXXFLAGS and reconfigure/recompile"
|
||||
#endif
|
||||
|
||||
#if defined(_lint) && !defined(lint)
|
||||
#define lint
|
||||
#endif
|
||||
|
||||
#ifndef stdin
|
||||
#include <stdio.h>
|
||||
#endif
|
||||
|
|
@ -502,7 +498,7 @@ C_MODE_END
|
|||
#endif
|
||||
|
||||
/* We might be forced to turn debug off, if not turned off already */
|
||||
#if (defined(FORCE_DBUG_OFF) || defined(_lint)) && !defined(DBUG_OFF)
|
||||
#if defined(FORCE_DBUG_OFF) && !defined(DBUG_OFF)
|
||||
# define DBUG_OFF
|
||||
# ifdef DBUG_ON
|
||||
# undef DBUG_ON
|
||||
|
|
@ -524,7 +520,7 @@ typedef int my_socket; /* File descriptor for sockets */
|
|||
#endif
|
||||
/* Type for functions that handles signals */
|
||||
#define sig_handler RETSIGTYPE
|
||||
#if defined(__GNUC__) && !defined(_lint)
|
||||
#if defined(__GNUC__)
|
||||
typedef char pchar; /* Mixed prototypes can take char */
|
||||
typedef char puchar; /* Mixed prototypes can take char */
|
||||
typedef char pbool; /* Mixed prototypes can take char */
|
||||
|
|
|
|||
|
|
@ -7699,7 +7699,7 @@ bool THD::binlog_for_noop_dml(bool transactional_table)
|
|||
}
|
||||
|
||||
|
||||
#if defined(DBUG_TRACE) && !defined(_lint)
|
||||
#if defined(DBUG_TRACE)
|
||||
static const char *
|
||||
show_query_type(THD::enum_binlog_query_type qtype)
|
||||
{
|
||||
|
|
@ -7713,7 +7713,7 @@ show_query_type(THD::enum_binlog_query_type qtype)
|
|||
DBUG_ASSERT(0 <= qtype && qtype < THD::QUERY_TYPE_COUNT);
|
||||
}
|
||||
static char buf[64];
|
||||
sprintf(buf, "UNKNOWN#%d", qtype);
|
||||
snprintf(buf, sizeof(buf), "UNKNOWN#%d", qtype);
|
||||
return buf;
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -836,9 +836,7 @@ public:
|
|||
inline void move_elements_to(I_List<T>* new_owner) {
|
||||
base_ilist::move_elements_to(new_owner);
|
||||
}
|
||||
#ifndef _lint
|
||||
friend class I_List_iterator<T>;
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -158,10 +158,8 @@ public:
|
|||
typedef I_P_List<T, B, C, I> Base;
|
||||
typedef I_P_List_iterator<T, Base> Iterator;
|
||||
typedef I_P_List_iterator<const T, Base> Const_Iterator;
|
||||
#ifndef _lint
|
||||
friend class I_P_List_iterator<T, Base>;
|
||||
friend class I_P_List_iterator<const T, Base>;
|
||||
#endif
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -236,9 +236,6 @@ end:
|
|||
}
|
||||
maria_end();
|
||||
my_exit(error);
|
||||
#ifndef _lint
|
||||
return 0; /* No compiler warning */
|
||||
#endif
|
||||
} /* main */
|
||||
|
||||
enum options_mc {
|
||||
|
|
|
|||
|
|
@ -289,11 +289,9 @@ end:
|
|||
maria_end();
|
||||
my_end(verbose ? MY_CHECK_ERROR | MY_GIVE_INFO : MY_CHECK_ERROR);
|
||||
exit(error ? 2 : 0);
|
||||
#ifndef _lint
|
||||
return 0; /* No compiler warning */
|
||||
#endif
|
||||
}
|
||||
|
||||
ATTRIBUTE_NORETURN
|
||||
static void my_exit(int error)
|
||||
{
|
||||
free_defaults(default_argv);
|
||||
|
|
|
|||
|
|
@ -337,7 +337,7 @@ static int mrn_change_encoding(grn_ctx *ctx, const CHARSET_INFO *charset)
|
|||
return mrn::encoding::set(ctx, charset);
|
||||
}
|
||||
|
||||
#if defined DBUG_TRACE && !defined(_lint)
|
||||
#if defined DBUG_TRACE
|
||||
static const char *mrn_inspect_thr_lock_type(enum thr_lock_type lock_type)
|
||||
{
|
||||
const char *inspected = "<unknown>";
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@
|
|||
|
||||
#define MRN_DBUG_ENTER_FUNCTION() DBUG_ENTER(__FUNCTION__)
|
||||
|
||||
#if !defined(DBUG_OFF) && !defined(_lint)
|
||||
#if !defined(DBUG_OFF)
|
||||
# define MRN_DBUG_ENTER_METHOD() \
|
||||
char method_name[MRN_MESSAGE_BUFFER_SIZE]; \
|
||||
method_name[0] = '\0'; \
|
||||
|
|
|
|||
|
|
@ -124,9 +124,6 @@ int main(int argc, char **argv)
|
|||
my_end(check_param.testflag & T_INFO ? MY_CHECK_ERROR | MY_GIVE_INFO : MY_CHECK_ERROR);
|
||||
rc= (uchar) error;
|
||||
exit(rc);
|
||||
#ifndef _lint
|
||||
return 0; /* No compiler warning */
|
||||
#endif
|
||||
} /* main */
|
||||
|
||||
enum options_mc {
|
||||
|
|
|
|||
|
|
@ -248,9 +248,6 @@ int main(int argc, char **argv)
|
|||
free_defaults(default_argv);
|
||||
my_end(verbose ? MY_CHECK_ERROR | MY_GIVE_INFO : MY_CHECK_ERROR);
|
||||
exit(error ? 2 : 0);
|
||||
#ifndef _lint
|
||||
return 0; /* No compiler warning */
|
||||
#endif
|
||||
}
|
||||
|
||||
enum options_mp {OPT_CHARSETS_DIR_MP=256};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue