hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mike Yoder (JIRA)" <j...@apache.org>
Subject [jira] [Created] (HADOOP-10816) key shell returns -1 to the shell on error, should be 1
Date Fri, 11 Jul 2014 22:31:05 GMT
Mike Yoder created HADOOP-10816:

             Summary: key shell returns -1 to the shell on error, should be 1
                 Key: HADOOP-10816
                 URL: https://issues.apache.org/jira/browse/HADOOP-10816
             Project: Hadoop Common
          Issue Type: Bug
          Components: security
    Affects Versions: 3.0.0
            Reporter: Mike Yoder

I've seen this in several places now - commands returning -1 on failure to the shell. It's
a bug. Someone confused their posix style returns (0 on success, < 0 on failure) with program
returns, which are an unsigned character. Thus, a return of -1 actually becomes 255 to the
$ hadoop key create happykey2 --provider kms://http@localhost:16000/kms --attr "a=a" --attr

Each attribute must correspond to only one value:
atttribute "a" was repeated


$ echo $?

A return value of 1 instead of -1 does the right thing.

This message was sent by Atlassian JIRA

View raw message