Fix #416 and partially #417

How I fixed it so far.
Percona Version string is
    mysql --version
    mysql  Ver 14.14 Distrib 5.6.21-70.1, for debian-linux-gnu (x86_64) using  EditLine wrapper

or

    mysql
    Welcome to the MySQL monitor.  Commands end with ; or \g.
    Your MySQL connection id is 236750
    Server version: 5.6.21-70.1-log Percona Server (GPL), Release 70.1, Revision 698
    
    Copyright (c) 2009-2014 Percona LLC and/or its affiliates
    Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
    
    Oracle is a registered trademark of Oracle Corporation and/or its
    affiliates. Other names may be trademarks of their respective
    owners.
    
    Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

on debian wheezy for package percona-server-server-5.6