~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to libdrizzle-2.0/command.cc

  • Committer: Mark Atwood
  • Date: 2011-11-15 04:19:11 UTC
  • mfrom: (2457.1.1 drizzle-docs71-2)
  • Revision ID: me@mark.atwood.name-20111115041911-mwcqz8tvfze0sgbo
lp:~hingo/drizzle/7.1-docs-reviewfixes

Show diffs side-by-side

added added

removed removed

Lines of Context:
120
120
  con->buffer_size-= con->command_size;
121
121
 
122
122
  if (con->command_offset == con->command_total)
123
 
  {
124
123
    drizzle_state_pop(con);
125
 
  }
126
124
  else
127
 
  {
128
125
    return DRIZZLE_RETURN_PAUSE;
129
 
  }
130
126
 
131
127
  return DRIZZLE_RETURN_OK;
132
128
}
163
159
                    + strlen(con->user) + 1
164
160
                    + 1  /* Scramble size */
165
161
                    + DRIZZLE_MAX_SCRAMBLE_SIZE
166
 
                    + strlen(con->schema) +1;
 
162
                    + strlen(con->db) + 1;
167
163
 
168
164
    /* Flush buffer if there is not enough room. */
169
165
    free_size= (size_t)DRIZZLE_MAX_BUFFER_SIZE - (size_t)(start - con->buffer);
178
174
    ptr= start;
179
175
    ptr[3]= 0;
180
176
    if (con->options & DRIZZLE_CON_MYSQL)
181
 
    {
182
 
      ptr[4]= uint8_t(con->command);
183
 
    }
 
177
      ptr[4]= (uint8_t)(con->command);
184
178
    else
185
 
    {
186
 
      ptr[4]= uint8_t(_command_drizzle_map[con->command]);
187
 
    }
 
179
      ptr[4]= (uint8_t)(_command_drizzle_map[con->command]);
188
180
    ptr+= 5;
189
181
 
190
182
    if (con->command == DRIZZLE_COMMAND_CHANGE_USER)