Bug #76737 Wrong exit code when asking for help
Submitted: 17 Apr 2015 12:44 Modified: 17 Apr 2015 13:25
Reporter: Honza Horak (OCA) Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Command-line Clients Severity:S3 (Non-critical)
Version:5.6.23, 5.1.73, 5.5.44, 5.6.25 OS:Any
Assigned to: CPU Architecture:Any

[17 Apr 2015 12:44] Honza Horak
Description:
There are weird exit codes of some utilities:

`mysql_waitpid --help` returns 255 instead of 0

`mysqladmin --help` returns 1 instead of 0

both of them accept '--help' (or '-?') as valid option according to the documentation

How to repeat:
$> mysql_waitpid --help &>/dev/null
$> echo $?

$> mysqladmin --help &>/dev/null
$> echo $?

Current resutls:
255
1

Expected results:
0
0
[17 Apr 2015 12:51] Honza Horak
Cross reporting:
https://mariadb.atlassian.net/browse/MDEV-8012