• unknown's avatar
    Bug #21288: mysqldump segmentation fault when using --where · 2ea03dc1
    unknown authored
      The problem was that the error handling was using a too-small buffer to
      print the error message generated. We fix this by not using a buffer at
      all, but by using fprintf() directly. There were also some problems with
      the error handling in table dumping that was exposed by this fix that were
      also corrected.
    
    
    client/mysqldump.c:
      Use fprintf() instead of my_printf_error() to avoid buffer overflow issues.
      Since ME_BELL wasn't specified, calling my_printf_error() offered no advantage
      except for adding my_progname, which we just go ahead and do manually. Also,
      fix the error handling in dumpTable() when queries to get data fail and --force
      was specified.
    mysql-test/r/mysqldump.result:
      Add new results
    mysql-test/t/mysqldump.test:
      Add new regression test
    2ea03dc1
mysqldump.c 81.4 KB