~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to client/drizzle.cc

  • Committer: Joe Daly
  • Date: 2010-04-04 02:03:28 UTC
  • mfrom: (1436 bad-staging)
  • mto: This revision was merged to the branch mainline in revision 1453.
  • Revision ID: skinny.moey@gmail.com-20100404020328-5ke55i58ywhgmw90
merge trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
1268
1268
  glob_buffer= new string();
1269
1269
  glob_buffer->reserve(512);
1270
1270
 
1271
 
  size_t output_buff_size = 512;
1272
 
  char * output_buff= (char *)malloc(output_buff_size);
1273
 
  memset(output_buff, '\0', output_buff_size);
1274
 
 
1275
 
  snprintf(output_buff, output_buff_size,
1276
 
           _("Your Drizzle connection id is %u\nServer version: %s\n"),
1277
 
           drizzle_con_thread_id(&con),
1278
 
           server_version_string(&con));
1279
 
  put_info(output_buff, INFO_INFO, 0, 0);
 
1271
  ostringstream output_buff;
 
1272
  output_buff << _("Your Drizzle connection id is ");
 
1273
  output_buff << drizzle_con_thread_id(&con);
 
1274
  output_buff << "\n";
 
1275
  output_buff << _("Server version: ");
 
1276
  output_buff << server_version_string(&con) << "\n";
 
1277
  put_info(output_buff.str().c_str(), INFO_INFO, 0, 0);
1280
1278
 
1281
1279
  initialize_readline(current_prompt);
1282
1280
  if (!status.batch && !quick)
2619
2617
    return 0;
2620
2618
 
2621
2619
  if (drizzle_con_error(&con)[0])
2622
 
    return put_error(&con, result);
 
2620
  {
 
2621
    int ret = put_error(&con, result);
 
2622
    drizzle_result_free(result);
 
2623
    return ret;
 
2624
  }
2623
2625
  return 0;
2624
2626
}
2625
2627