https://bugzilla.wikimedia.org/show_bug.cgi?id=19934

           Summary: Asynchronous upload from url uses wrong parameters when
                    processing download
           Product: MediaWiki
           Version: 1.16-svn
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: Normal
         Component: Uploading
        AssignedTo: wikibugs-l@lists.wikimedia.org
        ReportedBy: b-jor...@northwestern.edu


Created an attachment (id=6389)
 --> (https://bugzilla.wikimedia.org/attachment.cgi?id=6389)
Patch against r53755

When the upload API is used to make an asynchronous upload from a url, any
boolean parameters in the original request will be treated as "true" when the
download completes and the upload is processed; in particular, this means
asynchronous uploads always act as if ignorewarnings were specified.

The problem is that the API (due to using MediaWiki's WebRequest::getCheck)
considers only whether a boolean parameter exists and not what value it might
have, and the FauxRequest passed by the download-complete handler likely has
all boolean parameters set (to true or false).

One possible fix is to filter out those false boolean parameters before
creating the FauxRequest. The attached patch does just that.


-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
Wikibugs-l@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to