[rt-users] "1;" in the RT_SiteConfig.pm file
Wagner Pereira
wpereira at pop-sp.rnp.br
Wed May 19 08:22:08 EDT 2010
Thank Roderick and John very much to clarify this "exit code 1;" Perl's
stuff to me.
My best wishes.
Att,
--
Wagner Pereira
PoP-SP/RNP - Ponto de Presença da RNP em São Paulo
CCE/USP - Centro de Computação Eletrônica da Universidade de São Paulo
http://www.pop-sp.rnp.br
Tel. (11) 3091-8901
Em 18/5/2010 22:49, John Hascall escreveu:
>
>> Wagner Pereira wrote:
>>
>>> My 'easy' question is: what this "1;" does at the final? What is its
>>> utility? I don't remember if I had put it there or RT came with it by
>>> default.
>>>
>
>>> 1;
>>>
>
>> All "good" Perl modules have this as the exit code/value at the end.
>>
> More specifically, if I may quote from Wikipedia...
> # A Perl module must end with a true value or else it is considered not to
> # have loaded. By convention this value is usually 1 though it can be
> # any true value. A module can end with false to indicate failure but
> # this is rarely used and it would instead die() (exit with an error).
>
> John
>
> Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
> Buy a copy at http://rtbook.bestpractical.com
>
More information about the rt-users
mailing list