~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to mystrings/m_string.h

  • Committer: Monty Taylor
  • Date: 2008-10-07 09:36:42 UTC
  • mto: This revision was merged to the branch mainline in revision 489.
  • Revision ID: monty@inaugust.com-20081007093642-1uqwwt6z5u306cux
Split a method out into innodb_plugin_extras. Innodb is the only thing that uses it. I imagine we probably want to do something totally different with this...

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
#include <stdbool.h>
40
40
#include <assert.h>
41
41
#include <limits.h>
 
42
#include <ctype.h>
42
43
 
43
44
/*  This is needed for the definitions of memcpy... on solaris */
44
45
#if defined(HAVE_MEMORY_H) && !defined(__cplusplus)
172
173
#define USTRING_WITH_LEN(X) ((unsigned char*) X), ((size_t) (sizeof(X) - 1))
173
174
#define C_STRING_WITH_LEN(X) ((char *) (X)), ((size_t) (sizeof(X) - 1))
174
175
 
175
 
/* SPACE_INT32 is a word that contains only spaces */
176
 
#define SPACE_INT32 0x20202020
177
 
 
178
176
/**
179
177
  Skip trailing space.
180
178
 
183
181
   @return          the last non-space character
184
182
*/
185
183
 
186
 
static const unsigned char *
 
184
static inline const unsigned char *
187
185
skip_trailing_space(const unsigned char *ptr,size_t len)
188
186
{
189
187
  const unsigned char *end= ptr + len;