On 12/02/15 12:41, Sandro Bonazzola wrote:
Adding infra.
Il 12/02/2015 11:29, Yedidyah Bar David ha scritto:
> Hi all,
>
> The patch [1] for [2] is mostly ready.
>
> The patch [3] for otopi was already merged (by Alon) to master.
> It includes the following codes:
> 0 - success
> 1 - general error - the default if there was an error
> 2 - initialization error - returned if there was an error while loading
> plugins, before actually starting to run them
>
> These apply to all otopi-based tools.
>
> patch [1], not merged yet, currently adds this code, affecting engine-cleanup:
> 11 - cleanup called without setup.
> Returned in addition to the existing message:
> Could not detect a completed product setup
> Please use the cleanup utility only after a setup or after an upgrade from an older
installation.
>
> Comments are welcome:
>
> What other codes do you want to see?
> For automated testing or any other use?
>
> Do you think we should group them and allocate somehow?
> Just add a code whenever needed?
>
> If last is 'Yes', no need to think very much about the previous ones...
>
> [1]
http://gerrit.ovirt.org/35503
> [2]
https://bugzilla.redhat.com/show_bug.cgi?id=1079726
> [3]
http://gerrit.ovirt.org/35632
>
> Thanks,
>
Based on [1], it seems that it would be worth it to reserve some of the
codes for future use (like the usr codes).
Additionally, we should consider if we want to limit ourselves to 256
codes, to make sure we do not overflow someone. If this is needed, we
can reserve 255 to indicate overflow as mentioned in [2].
[1]
https://www.gnupg.org/documentation/manuals/gpgme/Error-Codes.html
[2]
http://www.tldp.org/LDP/abs/html/exitcodes.html