Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(735)

Issue 2579773003: Use int for fgetc() result in headless_shell (Closed)

Created:
4 years ago by Simon Hosie
Modified:
4 years ago
Reviewers:
cavalcantii1, Sami, altimin
CC:
chromium-reviews
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Use int for fgetc() result in headless_shell Fixes compilation failure introduced by c3ac4fc0. fgetc() returns its result as an _unsigned_ char and defines EOF as -1, and gives the result as an int. If char is unsigned it's impossible for EOF to match, and this results in a compilation error. If char is signed then potentially valid input could match EOF. BUG=674765 R=altimin@chromium.org, skyostil@chromium.org Change-Id: I979a8401e8c33d8983e7d1bee96b81bc555863ec Committed: https://crrev.com/b43d478991126401b0a03ef49438fcdcda961938 Cr-Commit-Position: refs/heads/master@{#439479}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1 line, -1 line) Patch
M headless/app/headless_shell.cc View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 14 (8 generated)
Simon Hosie
Note that this patch triggers the following presubmit message: These files spam the console log ...
4 years ago (2016-12-16 02:44:57 UTC) #1
Nico
On 2016/12/16 02:44:57, Simon Hosie wrote: > Note that this patch triggers the following presubmit ...
4 years ago (2016-12-16 02:57:01 UTC) #4
Sami
lgtm, thank you for the fix! On 2016/12/16 02:57:01, Nico (out Thu Dec 15) wrote: ...
4 years ago (2016-12-16 15:11:06 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2579773003/1
4 years ago (2016-12-19 15:18:44 UTC) #9
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years ago (2016-12-19 15:51:01 UTC) #12
commit-bot: I haz the power
4 years ago (2016-12-19 15:52:45 UTC) #14
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/b43d478991126401b0a03ef49438fcdcda961938
Cr-Commit-Position: refs/heads/master@{#439479}

Powered by Google App Engine
This is Rietveld 408576698