~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to libdrizzle/sql_common.h

  • Committer: Monty Taylor
  • Date: 2008-10-16 06:32:30 UTC
  • mto: (511.1.5 codestyle)
  • mto: This revision was merged to the branch mainline in revision 521.
  • Revision ID: monty@inaugust.com-20081016063230-4brxsra0qsmsg84q
Added -Wunused-macros.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* Copyright (C) 2003-2004, 2006 MySQL AB
2
 
   
3
 
   This program is free software; you can redistribute it and/or modify
4
 
   it under the terms of the GNU General Public License as published by
5
 
   the Free Software Foundation; version 2 of the License.
6
 
   
7
 
   This program is distributed in the hope that it will be useful,
8
 
   but WITHOUT ANY WARRANTY; without even the implied warranty of
9
 
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
10
 
   GNU General Public License for more details.
11
 
   
12
 
   You should have received a copy of the GNU General Public License
13
 
   along with this program; if not, write to the Free Software
14
 
   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA */
15
 
 
16
 
 
17
 
extern const char       *unknown_sqlstate;
18
 
extern const char       *cant_connect_sqlstate;
19
 
extern const char       *not_error_sqlstate;
 
1
/* - mode: c; c-basic-offset: 2; indent-tabs-mode: nil; -*-
 
2
 *  vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
 
3
 *
 
4
 *  Copyright (C) 2008 Sun Microsystems, Inc.
 
5
 *
 
6
 *  This program is free software; you can redistribute it and/or modify
 
7
 *  it under the terms of the GNU General Public License as published by
 
8
 *  the Free Software Foundation; version 2 of the License.
 
9
 *
 
10
 *  This program is distributed in the hope that it will be useful,
 
11
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
13
 *  GNU General Public License for more details.
 
14
 *
 
15
 *  You should have received a copy of the GNU General Public License
 
16
 *  along with this program; if not, write to the Free Software
 
17
 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 
18
 */
 
19
 
 
20
#ifndef _libdrizzle_sql_common_h
 
21
#define _libdrizzle_sql_common_h
20
22
 
21
23
#ifdef  __cplusplus
22
24
extern "C" {
23
25
#endif
24
26
 
25
 
extern CHARSET_INFO *default_client_charset_info;
26
 
MYSQL_FIELD *unpack_fields(MYSQL_DATA *data,MEM_ROOT *alloc,uint fields,
27
 
                           my_bool default_value, uint server_capabilities);
28
 
void free_rows(MYSQL_DATA *cur);
29
 
void free_old_query(MYSQL *mysql);
30
 
void end_server(MYSQL *mysql);
31
 
my_bool mysql_reconnect(MYSQL *mysql);
32
 
void mysql_read_default_options(struct st_mysql_options *options,
33
 
                                const char *filename,const char *group);
34
 
bool
35
 
cli_advanced_command(MYSQL *mysql, enum enum_server_command command,
36
 
                     const unsigned char *header, uint32_t header_length,
37
 
                     const unsigned char *arg, uint32_t arg_length, bool skip_check);
38
 
uint32_t cli_safe_read(MYSQL *mysql);
39
 
void net_clear_error(NET *net);
40
 
void set_mysql_error(MYSQL *mysql, int errcode, const char *sqlstate);
41
27
#ifdef  __cplusplus
42
28
}
43
29
#endif
44
30
 
45
 
#define protocol_41(A) ((A)->server_capabilities & CLIENT_PROTOCOL_41)
46
 
 
 
31
#endif