• Do not register here on develop.twiki.org, login with your twiki.org account.
• Use View topic Item7848 for generic doc work for TWiki-6.1.1. Use View topic Item7851 for doc work on extensions that are not part of a release. More... Close
• Anything you create or change in standard webs (Main, TWiki, Sandbox etc) will be automatically reverted on every SVN update.
Does this site look broken?. Use the LitterTray web for test cases.

Item5494: exit value is inverted

Item Form Data

AppliesTo: Component: Priority: CurrentState: WaitingFor: TargetRelease ReleasedIn
Extension UploadToTWikiAddOn Normal New   n/a  

Edit Form Data

Reported By:
Applies To:
Current State:
Waiting For:
Target Release:
Released In:


The error code returned after uploadtotwiki exits is inverted (as far as the shell is concerned): it returns 1 upon success, 0 upon failure.

The exit code is derived from the return of uploadFile ():

 exit uploadFile( $comment, $hide, $link, $delay, $url, @files );

which returns an appropriately Perlish result (1 for success, 0 for failure). This change

 exit !uploadFile( $comment, $hide, $link, $delay, $url, @files );
resolves the problem.

-- TWiki:Main/DiabJerius - 02 Apr 2008

Summary exit value is inverted
ReportedBy TWiki:Main.DiabJerius

SVN Range TWiki-5.0.0, Sun, 09 Mar 2008, build 16496
AppliesTo Extension
Component UploadToTWikiAddOn
Priority Normal
CurrentState New


TargetRelease n/a

Topic revision: r1 - 2008-04-02 - DiabJerius
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2022 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback