Bug 54831 - Use DEFINE_STATIC_LOCAL for ignoreSetMutex in Structure.cpp
Summary: Use DEFINE_STATIC_LOCAL for ignoreSetMutex in Structure.cpp
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Other OS X 10.5
: P2 Normal
Assignee: Patrick R. Gansterer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-20 12:58 PST by Patrick R. Gansterer
Modified: 2011-02-23 03:42 PST (History)
2 users (show)

See Also:


Attachments
Patch (2.22 KB, patch)
2011-02-20 12:59 PST, Patrick R. Gansterer
no flags Details | Formatted Diff | Diff
Patch (3.87 KB, patch)
2011-02-21 00:18 PST, Patrick R. Gansterer
no flags Details | Formatted Diff | Diff
Patch for landing (3.80 KB, patch)
2011-02-22 12:20 PST, Patrick R. Gansterer
no flags Details | Formatted Diff | Diff
Patch for landing (3.81 KB, patch)
2011-02-22 23:05 PST, Patrick R. Gansterer
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick R. Gansterer 2011-02-20 12:58:20 PST
Use DEFINE_STATIC_LOCAL for ignoreSetMutex in Structure.cpp
Comment 1 Patrick R. Gansterer 2011-02-20 12:59:15 PST
Created attachment 83100 [details]
Patch
Comment 2 Alexey Proskuryakov 2011-02-20 17:31:38 PST
Comment on attachment 83100 [details]
Patch

We should really initialize the mutex from JSC::initializeThreading() to avoid race conditions. I don't know why I didn't do that when adding this code.
Comment 3 Patrick R. Gansterer 2011-02-21 00:18:16 PST
Created attachment 83135 [details]
Patch
Comment 4 Alexey Proskuryakov 2011-02-21 15:14:27 PST
Comment on attachment 83135 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=83135&action=review

> Source/JavaScriptCore/runtime/InitializeThreading.cpp:59
> +    Structure::initializeThreading();
>  #if ENABLE(JSC_MULTIPLE_THREADS)

I think that it would be less confusing to have the call inside the #if - at least, I was confused by seeing it in the single thread section.
Comment 5 Patrick R. Gansterer 2011-02-22 12:20:17 PST
Created attachment 83360 [details]
Patch for landing
Comment 6 WebKit Commit Bot 2011-02-22 23:00:00 PST
Comment on attachment 83360 [details]
Patch for landing

Rejecting attachment 83360 [details] from commit-queue.

Failed to run "['./Tools/Scripts/webkit-patch', '--status-host=queues.webkit.org', '--bot-id=cr-jail-3', 'apply-..." exit_code: 2

Last 500 characters of output:
ScriptCore/runtime/Structure.cpp
Hunk #2 succeeded at 246 (offset -5 lines).
Hunk #3 succeeded at 279 with fuzz 2 (offset -9 lines).
Hunk #4 FAILED at 316.
Hunk #5 succeeded at 1185 (offset -38 lines).
1 out of 5 hunks FAILED -- saving rejects to file Source/JavaScriptCore/runtime/Structure.cpp.rej
patching file Source/JavaScriptCore/runtime/Structure.h
Hunk #1 succeeded at 136 (offset -9 lines).

Failed to run "[u'/mnt/git/webkit-commit-queue/Tools/Scripts/svn-apply', u'--force']" exit_code: 1

Full output: http://queues.webkit.org/results/7984037
Comment 7 Patrick R. Gansterer 2011-02-22 23:05:22 PST
Created attachment 83451 [details]
Patch for landing
Comment 8 WebKit Commit Bot 2011-02-23 03:42:20 PST
Comment on attachment 83451 [details]
Patch for landing

Clearing flags on attachment: 83451

Committed r79435: <http://trac.webkit.org/changeset/79435>
Comment 9 WebKit Commit Bot 2011-02-23 03:42:24 PST
All reviewed patches have been landed.  Closing bug.