~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to libdrizzle/net_serv.c

  • Committer: Brian Aker
  • Date: 2008-07-26 04:51:46 UTC
  • mfrom: (202.1.25 codestyle)
  • Revision ID: brian@tangent.org-20080726045146-ax7ofn8aqnkycjl3
Merge from Monty

Show diffs side-by-side

added added

removed removed

Lines of Context:
258
258
/**
259
259
  Send a command to the server.
260
260
 
261
 
    The reason for having both header and packet is so that libmysql
 
261
    The reason for having both header and packet is so that libdrizzle
262
262
    can easy add a header to a special command (like prepared statements)
263
263
    without having to re-alloc the string.
264
264
 
698
698
    }
699
699
    net->read_pos = net->buff + net->where_b;
700
700
    if (len != packet_error)
701
 
      net->read_pos[len]=0;             /* Safeguard for mysql_use_result */
 
701
      net->read_pos[len]=0;             /* Safeguard for drizzle_use_result */
702
702
    return len;
703
703
  }
704
704
  else
798
798
    len = ((ulong) (start_of_packet - first_packet_offset) - NET_HEADER_SIZE -
799
799
           multi_byte_packet);
800
800
    net->save_char= net->read_pos[len]; /* Must be saved */
801
 
    net->read_pos[len]=0;               /* Safeguard for mysql_use_result */
 
801
    net->read_pos[len]=0;               /* Safeguard for drizzle_use_result */
802
802
  }
803
803
  return len;
804
804
}