Closed
Bug 1435223
Opened 6 years ago
Closed 6 years ago
LinuxGamepad.cpp: -Wformat-truncation warning on an snprintf
Categories
(Core :: DOM: Core & HTML, defect)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
mozilla60
Tracking | Status | |
---|---|---|
firefox60 | --- | fixed |
People
(Reporter: Sylvestre, Assigned: Sylvestre)
References
Details
Attachments
(1 file)
In file included from /root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dom/gamepad/Unified_cpp_dom_gamepad0.cpp:110: /root/firefox-gcc-last/dom/gamepad/linux/LinuxGamepad.cpp: In member function 'void {anonymous}::LinuxGamepadService::AddDevice(mozilla::udev_device*)': /root/firefox-gcc-last/dom/gamepad/linux/LinuxGamepad.cpp:137:12: error: '%s' directive output may be truncated writing up to 127 bytes into a region of size between 112 and 126 [-Werror=format-truncation=] "%s-%s-%s", ^~~~~~~~~~
Comment hidden (mozreview-request) |
Assignee | ||
Comment 2•6 years ago
|
||
Another solution could be to truncate the "name" variable so that we are always until 128 bytes. I did it the lazy way!
Comment 3•6 years ago
|
||
mozreview-review |
Comment on attachment 8947772 [details] Bug 1435223 - Increase the size of idstring to avoid a warning https://reviewboard.mozilla.org/r/217494/#review223300
Attachment #8947772 -
Flags: review?(amarchesini) → review+
Pushed by sledru@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/86e0f2c3cc2d Increase the size of idstring to avoid a warning r=baku
Comment 5•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/86e0f2c3cc2d
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla60
Updated•5 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•