~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to mysys/my_error.c

  • Committer: Monty Taylor
  • Date: 2008-08-04 19:37:18 UTC
  • mto: (261.2.2 codestyle)
  • mto: This revision was merged to the branch mainline in revision 262.
  • Revision ID: monty@inaugust.com-20080804193718-f0rz13uli4429ozb
Changed gettext_noop() to N_()

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
   along with this program; if not, write to the Free Software
14
14
   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA */
15
15
 
16
 
#include <stdio.h>
17
16
#include "mysys_priv.h"
18
 
#include <drizzled/gettext.h>
19
17
#include "mysys_err.h"
20
18
#include <mystrings/m_string.h>
21
19
#include <stdarg.h>
22
20
#include <mystrings/m_ctype.h>
 
21
#include <libdrizzle/gettext.h>
23
22
 
24
23
/* Define some external variables for error handling */
25
24
 
107
106
      ...       variable list
108
107
*/
109
108
 
110
 
void my_printf_error(uint32_t error, const char *format, myf MyFlags, ...)
 
109
void my_printf_error(uint error, const char *format, myf MyFlags, ...)
111
110
{
112
111
  va_list args;
113
112
  char ebuff[ERRMSGSIZE+20];
129
128
      MyFlags   Flags
130
129
*/
131
130
 
132
 
void my_message(uint32_t error, const char *str, register myf MyFlags)
 
131
void my_message(uint error, const char *str, register myf MyFlags)
133
132
{
134
133
  (*error_handler_hook)(error, str, MyFlags);
135
134
}
183
182
  /* Error numbers must be unique. No overlapping is allowed. */
184
183
  if (*search_meh_pp && ((*search_meh_pp)->meh_first <= last))
185
184
  {
186
 
    free((unsigned char*)meh_p);
 
185
    my_free((uchar*)meh_p, MYF(0));
187
186
    return 1;
188
187
  }
189
188
 
241
240
  errmsgs= meh_p->meh_errmsgs;
242
241
  bool is_globerrs= meh_p->is_globerrs;
243
242
 
244
 
  free((unsigned char*) meh_p);
 
243
  my_free((uchar*) meh_p, MYF(0));
245
244
 
246
245
  if (is_globerrs)
247
246
    return NULL;
256
255
  for (list= my_errmsgs_globerrs.meh_next; list; list= next)
257
256
  {
258
257
    next= list->meh_next;
259
 
    free((unsigned char*) list);
 
258
    my_free((uchar*) list, MYF(0));
260
259
  }
261
260
  my_errmsgs_list= &my_errmsgs_globerrs;
262
261
}