WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
111467
Each web process truncates the disk cache to zero on launch
https://bugs.webkit.org/show_bug.cgi?id=111467
Summary
Each web process truncates the disk cache to zero on launch
Geoffrey Garen
Reported
2013-03-05 12:40:45 PST
Each web process truncates the disk cache to zero on launch
Attachments
Patch
(2.71 KB, patch)
2013-03-05 12:42 PST
,
Geoffrey Garen
darin
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Geoffrey Garen
Comment 1
2013-03-05 12:42:57 PST
Created
attachment 191537
[details]
Patch
Darin Adler
Comment 2
2013-03-05 14:04:19 PST
Comment on
attachment 191537
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=191537&action=review
> Source/WebKit2/WebProcess/mac/WebProcessMac.mm:165 > + NSUInteger cacheMemoryCapacity = parameters.nsURLCacheMemoryCapacity; > + NSUInteger cacheDiskCapacity = parameters.nsURLCacheDiskCapacity;
Strange to put two arguments into local variables here, but not the third. All three or none?
> Source/WebKit2/WebProcess/mac/WebProcessMac.mm:168 > + RetainPtr<NSURLCache> parentProcessURLCache(AdoptNS, [[NSURLCache alloc] initWithMemoryCapacity:cacheMemoryCapacity diskCapacity:cacheDiskCapacity diskPath:parameters.diskCacheDirectory]); > + [NSURLCache setSharedURLCache:parentProcessURLCache.get()];
Wrong indentation here.
Geoffrey Garen
Comment 3
2013-03-05 18:15:35 PST
Committed
r144860
: <
http://trac.webkit.org/changeset/144860
>
Darin Adler
Comment 4
2013-03-06 11:23:14 PST
More style comments for Geoff: 1) The adoptNS function is so much better than RetainPtr<xxx> yyy(AdoptNS, zzz). 2) No local variable needed. So next time I have a chance I’d just change this to: [NSURLCache setSharedURLCache:adoptNS([[NSURLCache alloc] initWithMemoryCapacity:parameters.nsURLCacheMemoryCapacity diskCapacity:parameters.nsURLCacheDiskCapacity diskPath:parameters.diskCacheDirectory]).get()]; Just wanted to get you into the adoptNS/adoptCF/adoptRef club!
Geoffrey Garen
Comment 5
2013-03-06 11:50:26 PST
Committed
r144958
: <
http://trac.webkit.org/changeset/144958
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug