Last Comment Bug 727156 - fix warnings in toolkit/mozapps/update/
: fix warnings in toolkit/mozapps/update/
Status: RESOLVED FIXED
[qa-]
:
Product: Toolkit
Classification: Components
Component: Application Update (show other bugs)
: unspecified
: All All
: -- normal (vote)
: mozilla12
Assigned To: Nathan Froyd [:froydnj]
:
:
Mentors:
Depends on:
Blocks: buildwarning
  Show dependency treegraph
 
Reported: 2012-02-14 10:47 PST by Nathan Froyd [:froydnj]
Modified: 2012-03-29 12:15 PDT (History)
4 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
unaffected
fixed
fixed


Attachments
patch (4.94 KB, patch)
2012-02-14 10:49 PST, Nathan Froyd [:froydnj]
netzen: review-
Details | Diff | Splinter Review
patch (4.31 KB, patch)
2012-02-14 11:14 PST, Nathan Froyd [:froydnj]
no flags Details | Diff | Splinter Review
patch (4.33 KB, patch)
2012-02-14 11:25 PST, Nathan Froyd [:froydnj]
netzen: review+
Details | Diff | Splinter Review

Description Nathan Froyd [:froydnj] 2012-02-14 10:47:04 PST
There's a couple different warnings here:

* set-but-unused variables
* unused functions (!)
* const char * -> char * warnings

Let's go ahead and fix them all in one go.
Comment 1 Nathan Froyd [:froydnj] 2012-02-14 10:49:48 PST
Created attachment 597089 [details] [diff] [review]
patch
Comment 2 Brian R. Bondy [:bbondy] 2012-02-14 11:05:09 PST
Comment on attachment 597089 [details] [diff] [review]
patch

Review of attachment 597089 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks for the patch.
But we need to tweak the ifdefs instead of removing those functions.

::: toolkit/mozapps/update/updater/updater.cpp
@@ -1461,5 @@
> - * @return true if the information was retrieved and it is pending
> - *         or pending-service.
> -*/
> -static bool
> -IsUpdateStatusPending(bool &isPendingService)

This is needed when #ifdef MOZ_MAINTENANCE_SERVICE (which happens currently on windows x86)

@@ -1495,5 @@
> - *         is set to succeeded or not.
> - * @return true if the information was retrieved and it is succeeded.
> -*/
> -static bool
> -IsUpdateStatusSucceeded(bool &isSucceeded)

This is needed on Windows so when #ifdef XP_WIN.
Comment 3 Nathan Froyd [:froydnj] 2012-02-14 11:14:18 PST
Created attachment 597109 [details] [diff] [review]
patch

Thanks for the pointers.  That's the fun of fixing compiler warnings, isn't it?
Comment 4 Brian R. Bondy [:bbondy] 2012-02-14 11:18:31 PST
Comment on attachment 597109 [details] [diff] [review]
patch

Review of attachment 597109 [details] [diff] [review]:
-----------------------------------------------------------------

One last pass pls :D
Also pls run through try to make sure it builds fine on x64 and Windows x86.

::: toolkit/mozapps/update/updater/updater.cpp
@@ +1522,2 @@
>  
>  #ifdef XP_WIN

The previous #ifdef XP_WIN can be combined with this one.
Comment 5 Nathan Froyd [:froydnj] 2012-02-14 11:25:43 PST
Created attachment 597113 [details] [diff] [review]
patch
Comment 6 Mozilla RelEng Bot 2012-02-14 11:32:59 PST
Autoland Patchset:
	Patches: 597113
	Branch: mozilla-central => try
	Destination: http://hg.mozilla.org/try/pushloghtml?changeset=b19c8e48aeaf
Try run started, revision b19c8e48aeaf. To cancel or monitor the job, see: https://tbpl.mozilla.org/?tree=Try&rev=b19c8e48aeaf
Comment 7 Brian R. Bondy [:bbondy] 2012-02-14 11:33:52 PST
Comment on attachment 597113 [details] [diff] [review]
patch

Review of attachment 597113 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks for cleaning this up, you're good to go as long as it passes try.
Comment 8 Mozilla RelEng Bot 2012-02-14 19:01:16 PST
Try run for b19c8e48aeaf is complete.
Detailed breakdown of the results available here:
    https://tbpl.mozilla.org/?tree=Try&rev=b19c8e48aeaf
Results (out of 210 total builds):
    success: 177
    warnings: 19
    failure: 14
Builds (or logs if builds failed) available at:
http://ftp.mozilla.org/pub/mozilla.org/firefox/try-builds/autolanduser@mozilla.com-b19c8e48aeaf
Comment 10 Marco Bonardo [::mak] 2012-02-16 02:50:12 PST
https://hg.mozilla.org/mozilla-central/rev/a8634484e86b
Comment 11 Brian R. Bondy [:bbondy] 2012-02-29 18:37:57 PST
http://hg.mozilla.org/releases/mozilla-aurora/rev/18840d884c97

Note You need to log in before you can comment on or make changes to this bug.