~clint-fewbar/ubuntu/lucid/mysql-dfsg-5.1/increase-killtimeout

« back to all changes in this revision

Viewing changes to storage/myisam/mi_search.c

  • Committer: Bazaar Package Importer
  • Author(s): Chuck Short
  • Date: 2009-12-08 03:05:40 UTC
  • mfrom: (1.1.4 upstream) (0.1.15 sid)
  • Revision ID: james.westby@ubuntu.com-20091208030540-l5xq57znyuy9ctgt
Tags: 5.1.41-3ubuntu1
* Merge from debian testing.  Remaining changes:
  - debian/control:
    + Don't provide a libmysqlclient15-dev package as long as there
      are packages still build-depending on libmysqlclient15-dev and
      mysql-dfsg-5.0 is in the archive.
    + Lower mailx from a Recommends to a Suggests to avoid pulling in a
      full MTA on all installs of mysql-server (LP: #259477)
  - debian/rules:
    + added -fno-strict-aliasing to CFLAGS to get around mysql testsuite
      build failures.
  - debian/additions/debian-start.inc.sh: support ANSI mode (LP: #310211)
  - Add AppArmor profile:
    + debian/apparmor-profile: apparmor profile
    + debian/rules, debian/mysql-server-5.1.files: install apparmor profile.
    + debian/mysql-server-5.1.dirs: add etc/apparmor.d/fore-complain
    + debian/mysql-server-5.1.postrm: remove symlink in force-complain/ on
      purge.
    + debian/mysql-server-5.1.README.Debian: add apparmor documentation.
    + debian/additions/my.cnf: Add warning about apparmor. (LP: #201799)
    + debian/mysql-esrver-5.1.postinst: reload apparmor profiles
  - debian/additions/my.cfn: remove language options. Error message files are
    located in a different direction in Mysql 5.0. Setting the language option
    to use /usr/share/mysql/english breaks 5.0. Both 5.0 and 5.1 use a 
    default value that works. (LP: #316974)
  - debian/mysql-server-5.1.postinst: Clear out the second password when
    setting up mysql. (LP: #344816)
  - mysql-server-core-5.1 package for files needed by Akonadi:
    + debian/control: create mysql-server-core-5.1 package
    + debian/mysql-server-core-5.1.files, debian/mysql-server-5.1.files:
      move core mysqld files to mysql-server-core-5.1 package.
  - debian/libmysqlclient16.symbols.amd64: remove amd64 symbols as it has
    not been correcly generated in Debian.
  - Add Apport hook: (LP: #354188):
    + debian/mysql-server-5.1.py: apport package hook
    + debian/mysql-server-5.1.files, debian/rules: install apport package hook
  - debian/addtions/my.cnf:
    + drop old_password option.
    + fix commentened logging options to use general_log and general_log_file.
  - Don't upgrade if there is an ndb management node configured (LP: #413792)
  - Set thread stack size to 192K rather than 128K. 128K is only useful on 
    systems with < 64M RAM and causes stack overrides with some SQL commands.
    See http://dev.mysql.com/doc/refman/5.1/en/server-system-varriables.html
    for more details. (LP: #426919)
  - Convert to upstart:
    + Add mysql-server-5.1.mysql.upstart
    + Dropped debian/mysql-server-5.1.mysql.init,
      debian/additions/mysqld_safe_syslog.cnf
    + debian/additions/my.cnf:
      * Removed pid declaration
      * Set up error logging to /var/log/mysql since we're not piping anything
        around logger anymore
    + Remove references to mysqld_safe in these files:
      * debian/rules, mysql-server-5.1.logcheck.ignore.paranoid
        mysql-server-5.1.logcheck.ignore.workstation, 
        mysql-server-5.1.logcheck.ignore.server
    + debian/mysql-server-5.1.postinst:
      * Replace calls to /etc/init.d with regular upstart calls
      * Remove reference to mysqld_safe
    + Dropped debian/patches/38_scripts_mysqld_safe.sh_signals.dpatch:
  - Dropped already merged upstream:
    + debian/{control,rules}: add and enable hardening build for PIE.
   

Show diffs side-by-side

added added

removed removed

Lines of Context:
28
28
{
29
29
  if (inx == -1)                        /* Use last index */
30
30
    inx=info->lastinx;
31
 
  if (inx < 0 || ! mi_is_key_active(info->s->state.key_map, inx))
32
 
  {
33
 
    my_errno=HA_ERR_WRONG_INDEX;
 
31
  if (inx < 0)
 
32
  {
 
33
    my_errno= HA_ERR_WRONG_INDEX;
 
34
    return -1;
 
35
  }
 
36
  if (!mi_is_key_active(info->s->state.key_map, inx))
 
37
  {
 
38
    my_errno= info->s->state.state.records ? HA_ERR_WRONG_INDEX :
 
39
                                             HA_ERR_END_OF_FILE;
34
40
    return -1;
35
41
  }
36
42
  if (info->lastinx != inx)             /* Index changed */
240
246
                   uchar *key, uint key_len, uint comp_flag, uchar **ret_pos,
241
247
                   uchar *buff, my_bool *last_key)
242
248
{
243
 
  int flag;
244
 
  uint nod_flag,length,not_used[2];
 
249
  int UNINIT_VAR(flag);
 
250
  uint nod_flag,UNINIT_VAR(length),not_used[2];
245
251
  uchar t_buff[MI_MAX_KEY_BUFF],*end;
246
252
  DBUG_ENTER("_mi_seq_search");
247
253
 
248
 
  LINT_INIT(flag); LINT_INIT(length);
249
254
  end= page+mi_getint(page);
250
255
  nod_flag=mi_test_if_nod(page);
251
256
  page+=2+nod_flag;
297
302
  uchar *end, *kseg, *vseg;
298
303
  uchar *sort_order=keyinfo->seg->charset->sort_order;
299
304
  uchar tt_buff[MI_MAX_KEY_BUFF+2], *t_buff=tt_buff+2;
300
 
  uchar *saved_from, *saved_to, *saved_vseg;
 
305
  uchar *UNINIT_VAR(saved_from), *UNINIT_VAR(saved_to);
 
306
  uchar *UNINIT_VAR(saved_vseg);
301
307
  uint  saved_length=0, saved_prefix_len=0;
302
308
  uint  length_pack;
303
309
  DBUG_ENTER("_mi_prefix_search");
305
311
  LINT_INIT(length);
306
312
  LINT_INIT(prefix_len);
307
313
  LINT_INIT(seg_len_pack);
308
 
  LINT_INIT(saved_from);
309
 
  LINT_INIT(saved_to);
310
 
  LINT_INIT(saved_vseg);
311
314
 
312
315
  t_buff[0]=0;                                  /* Avoid bugs */
313
316
  end= page+mi_getint(page);