~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/db.cc

  • Committer: Toru Maesaka
  • Date: 2008-12-14 08:26:38 UTC
  • mto: (670.1.24 devel)
  • mto: This revision was merged to the branch mainline in revision 676.
  • Revision ID: dev@torum.net-20081214082638-c8uje8oiwk4s2dh0
First pass of replacing MySQL's strxmov with libc alternatives

Show diffs side-by-side

added added

removed removed

Lines of Context:
628
628
 
629
629
    if (!session->query)                                // Only in replication
630
630
    {
631
 
      query=         tmp_query;
632
 
      query_length= (uint) (strxmov(tmp_query,"create database `",
633
 
                                    db, "`", NULL) - tmp_query);
 
631
      query= tmp_query;
 
632
      query_length= sprintf(tmp_query, "create database `%s`", db);
634
633
    }
635
634
    else
636
635
    {
841
840
    {
842
841
      /* The client used the old obsolete mysql_drop_db() call */
843
842
      query= path;
844
 
      query_length= (uint) (strxmov(path, "drop database `", db, "`",
845
 
                                     NULL) - path);
 
843
      query_length= sprintf(path, "drop database `%s`", db);
846
844
    }
847
845
    else
848
846
    {
849
 
      query =session->query;
 
847
      query= session->query;
850
848
      query_length= session->query_length;
851
849
    }
852
850
    if (drizzle_bin_log.is_open())
1000
998
    }
1001
999
    else
1002
1000
    {
1003
 
      strxmov(filePath, org_path, "/", file->name, NULL);
 
1001
      sprintf(filePath, "%s/%s", org_path, file->name);
1004
1002
      if (my_delete_with_symlink(filePath,MYF(MY_WME)))
1005
1003
      {
1006
1004
        goto err;