~ubuntu-branches/debian/squeeze/mysql-5.1/squeeze

« back to all changes in this revision

Viewing changes to storage/myisam/mi_dynrec.c

  • Committer: Package Import Robot
  • Author(s): Moritz Muehlenhoff
  • Date: 2014-01-14 10:40:30 UTC
  • mfrom: (1.1.5)
  • Revision ID: package-import@ubuntu.com-20140114104030-44alii0hx3x3g41y
Tags: 5.1.73-1
* New upstream release
  http://dev.mysql.com/doc/relnotes/mysql/5.1/en/news-5-1-73.html
* Update patches
* Disable flaky test rpl.rpl_innodb_bug28430 breaking the build. It's  marked
  as experimental by upstream and the internet is full of reports about it's
  unrelialibity

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* Copyright (C) 2000-2006 MySQL AB
 
1
/*
 
2
   Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
2
3
 
3
4
   This program is free software; you can redistribute it and/or modify
4
5
   it under the terms of the GNU General Public License as published by
11
12
 
12
13
   You should have received a copy of the GNU General Public License
13
14
   along with this program; if not, write to the Free Software
14
 
   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA */
 
15
   Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301  USA
 
16
*/
15
17
 
16
18
/*
17
19
  Functions to handle space-packed-records and blobs
66
68
my_bool mi_dynmap_file(MI_INFO *info, my_off_t size)
67
69
{
68
70
  DBUG_ENTER("mi_dynmap_file");
69
 
  if (size > (my_off_t) (~((size_t) 0)))
 
71
  if (size == 0 || size > (my_off_t) (~((size_t) 0)))
70
72
  {
71
 
    DBUG_PRINT("warning", ("File is too large for mmap"));
 
73
    if (size)
 
74
      DBUG_PRINT("warning", ("File is too large for mmap"));
 
75
    else
 
76
      DBUG_PRINT("warning", ("Do not mmap zero-length"));
72
77
    DBUG_RETURN(1);
73
78
  }
74
79
  /*