Last Comment Bug 719538 - use nsIWindowsRegKey in Windows shell service
: use nsIWindowsRegKey in Windows shell service
Status: RESOLVED FIXED
:
Product: Firefox
Classification: Client Software
Component: Shell Integration (show other bugs)
: Trunk
: All Windows 7
: -- normal (vote)
: Firefox 12
Assigned To: :Gavin Sharp [email: gavin@gavinsharp.com]
:
Mentors:
Depends on:
Blocks: 662324
  Show dependency treegraph
 
Reported: 2012-01-19 12:05 PST by :Gavin Sharp [email: gavin@gavinsharp.com]
Modified: 2012-01-21 07:11 PST (History)
2 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
patch (5.81 KB, patch)
2012-01-19 12:05 PST, :Gavin Sharp [email: gavin@gavinsharp.com]
jmathies: review+
Details | Diff | Splinter Review
patch (5.81 KB, patch)
2012-01-19 13:36 PST, :Gavin Sharp [email: gavin@gavinsharp.com]
jmathies: review+
Details | Diff | Splinter Review

Description :Gavin Sharp [email: gavin@gavinsharp.com] 2012-01-19 12:05:12 PST
...instead of calling the registry APIs directly
Comment 1 :Gavin Sharp [email: gavin@gavinsharp.com] 2012-01-19 12:05:56 PST
Created attachment 589939 [details] [diff] [review]
patch
Comment 2 Jim Mathies [:jimm] 2012-01-19 13:09:07 PST
Comment on attachment 589939 [details] [diff] [review]
patch

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

::: browser/components/shell/src/nsWindowsShellService.cpp
@@ +785,5 @@
> +                      nsIWindowsRegKey::ACCESS_SET_VALUE);
> +  NS_ENSURE_SUCCESS(rv, rv);
> +
> +  char rgb[12];
> +  sprintf((char*)rgb, "%u %u %u\0", r, g, b);

Couldn't we print this into a PRUnichar buf and skip the use of NS_ConvertUTF8toUTF16 all together?
Comment 3 :Gavin Sharp [email: gavin@gavinsharp.com] 2012-01-19 13:36:50 PST
Created attachment 589977 [details] [diff] [review]
patch

please double check my _snwprintfing!
Comment 4 Jim Mathies [:jimm] 2012-01-19 13:50:29 PST
Comment on attachment 589977 [details] [diff] [review]
patch

look ok to me!
Comment 5 :Gavin Sharp [email: gavin@gavinsharp.com] 2012-01-19 14:17:01 PST
https://hg.mozilla.org/integration/mozilla-inbound/rev/eb09304af438
Comment 6 Ed Morley [:emorley] 2012-01-21 07:11:40 PST
https://hg.mozilla.org/mozilla-central/rev/eb09304af438

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