Bug 141794

Summary: Fix build warning in WebKit2/WebProcess and UIProcess module
Product: WebKit Reporter: Shivakumar J M <shiva.jm>
Component: New BugsAssignee: Shivakumar J M <shiva.jm>
Status: RESOLVED FIXED    
Severity: Normal CC: andersca, commit-queue, gyuyoung.kim, ossy, thorton
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
andersca: review-
Patch-Updated-Review1 none

Description Shivakumar J M 2015-02-19 02:07:11 PST
Got below build warning on latest build, might have casued by issue: https://bugs.webkit.org/show_bug.cgi?id=141724

../../Source/WebKit2/UIProcess/WebsiteData/WebsiteDataStore.cpp:115:26: warning: unused parameter ‘isNonPersistentStore’ [-Wunused-parameter]
 static ProcessAccessType computeWebProcessAccessType(WebsiteDataTypes dataTypes, bool isNonPersistentStore)
                          ^
[4500/5125] Building CXX object Source/WebKit2/CMakeFiles/WebKit2.dir/WebProcess/Databases/IndexedDB/WebIDBFactoryBackend.cpp.o
[4501/5125] Building CXX object Source/WebKit2/CMakeFiles/WebKit2.dir/WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp.o
[4502/5125] Building CXX object Source/WebKit2/CMakeFiles/WebKit2.dir/WebProcess/Databases/WebToDatabaseProcessConnection.cpp.o
[4503/5125] Building CXX object Source/WebKit2/CMakeFiles/WebKit2.dir/WebProcess/FileAPI/BlobRegistryProxy.cpp.o
[4504/5125] Building CXX object Source/WebKit2/CMakeFiles/WebKit2.dir/WebProcess/FullScreen/WebFullScreenManager.cpp.o
../../Source/WebKit2/WebProcess/WebProcess.cpp:1136:6: warning: unused parameter ‘modifiedSince’ [-Wunused-parameter]
 void WebProcess::deleteWebsiteData(SessionID sessionID, uint64_t websiteDataTypes, std::chrono::system_clock::time_point modifiedSince, uint64_t callbackID)
Comment 1 Shivakumar J M 2015-02-19 02:11:39 PST
Created attachment 246887 [details]
Patch

Fix build warnings by removing parameter name from functions
Comment 2 Csaba Osztrogonác 2015-02-19 03:26:07 PST
Comment on attachment 246887 [details]
Patch

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

> Source/WebKit2/UIProcess/WebsiteData/WebsiteDataStore.cpp:115
> -static ProcessAccessType computeWebProcessAccessType(WebsiteDataTypes dataTypes, bool isNonPersistentStore)
> +static ProcessAccessType computeWebProcessAccessType(WebsiteDataTypes dataTypes, bool)

I don't know why http://trac.webkit.org/changeset/180265 added 
this unused parameter to computeWebProcessAccessType().

This function is called from one place with passing this unused parameter.
If it isn't passed due to recent / planned feature, I'd remove it completely.

Anders?

> Source/WebKit2/WebProcess/WebProcess.cpp:1136
> -void WebProcess::deleteWebsiteData(SessionID sessionID, uint64_t websiteDataTypes, std::chrono::system_clock::time_point modifiedSince, uint64_t callbackID)
> +void WebProcess::deleteWebsiteData(SessionID sessionID, uint64_t websiteDataTypes, std::chrono::system_clock::time_point, uint64_t callbackID)

It seems it can be removed. But why can't we remove it from the message and from WebPageProxy too if it is unused?
Or is it intentional to have exactly the same deleteWebsiteData message format in WebProcess and Networkprocess?
Comment 3 Anders Carlsson 2015-02-19 06:25:57 PST
Comment on attachment 246887 [details]
Patch

This is work in progress. I'd rather this used UNUSED_PARAM for now!
Comment 4 Shivakumar J M 2015-02-19 20:28:28 PST
Created attachment 246935 [details]
Patch-Updated-Review1

updated the patch with review comments
Comment 5 WebKit Commit Bot 2015-02-19 22:14:22 PST
Comment on attachment 246935 [details]
Patch-Updated-Review1

Clearing flags on attachment: 246935

Committed r180386: <http://trac.webkit.org/changeset/180386>
Comment 6 WebKit Commit Bot 2015-02-19 22:14:26 PST
All reviewed patches have been landed.  Closing bug.