Bug 162678 - woff2 upgrade introduces compiler warnings
Summary: woff2 upgrade introduces compiler warnings
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: WebKit Nightly Build
Hardware: PC Linux
: P2 Minor
Assignee: Michael Catanzaro
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-09-28 08:44 PDT by Michael Catanzaro
Modified: 2016-09-29 01:36 PDT (History)
4 users (show)

See Also:


Attachments
Patch (1.21 KB, patch)
2016-09-28 08:47 PDT, Michael Catanzaro
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Catanzaro 2016-09-28 08:44:04 PDT
Please fix compiler warnings before submitting patches! It seems unlikely that your compiler didn't warn about these:

[22/78] Building CXX object Source/Thi...MakeFiles/woff2.dir/src/woff2_dec.cc.o
../../Source/ThirdParty/woff2/src/woff2_dec.cc: In function ‘bool woff2::{anonymous}::ReadWOFF2Header(const uint8_t*, size_t, woff2::{anonymous}::WOFF2Header*)’:
../../Source/ThirdParty/woff2/src/woff2_dec.cc:1140:12: warning: unused variable ‘dst_offset’ [-Wunused-variable]
   uint64_t dst_offset = first_table_offset;
            ^~~~~~~~~~
../../Source/ThirdParty/woff2/src/woff2_dec.cc: In function ‘bool woff2::{anonymous}::WriteHeaders(const uint8_t*, size_t, woff2::{anonymous}::RebuildMetadata*, woff2::{anonymous}::WOFF2Header*, woff2::WOFF2Out*)’:
../../Source/ThirdParty/woff2/src/woff2_dec.cc:1179:34: warning: unused parameter ‘data’ [-Wunused-parameter]
 bool WriteHeaders(const uint8_t* data, size_t length, RebuildMetadata* metadata,
                                  ^~~~
../../Source/ThirdParty/woff2/src/woff2_dec.cc:1179:47: warning: unused parameter ‘length’ [-Wunused-parameter]
 bool WriteHeaders(const uint8_t* data, size_t length, RebuildMetadata* metadata,
                                               ^~~~~~
Comment 1 Michael Catanzaro 2016-09-28 08:47:38 PDT
Created attachment 290085 [details]
Patch
Comment 2 WebKit Commit Bot 2016-09-28 12:34:58 PDT
Comment on attachment 290085 [details]
Patch

Clearing flags on attachment: 290085

Committed r206532: <http://trac.webkit.org/changeset/206532>
Comment 3 WebKit Commit Bot 2016-09-28 12:35:01 PDT
All reviewed patches have been landed.  Closing bug.
Comment 4 Konstantin Tokarev 2016-09-28 12:38:39 PDT
Comment on attachment 290085 [details]
Patch

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

> Source/ThirdParty/woff2/CMakeLists.txt:22
> +    ADD_TARGET_PROPERTIES(woff2 COMPILE_FLAGS "-Wno-sign-compare -Wunused-variable -Wunused-parameter")

I think you've meant -Wno-unused-variable -Wno-unused-parameter
Comment 5 Konstantin Tokarev 2016-09-28 12:50:23 PDT
Committed r206535: <http://trac.webkit.org/changeset/206535>
Comment 6 Michael Catanzaro 2016-09-29 01:36:29 PDT
Sigh, thanks... I guess I must not have tested it at all....