Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home for chromium.org
« Groups Home
Message from discussion Migrate Graphics2D to new design. (issue 11053003)

Received: by 10.236.85.176 with SMTP id u36mr131700yhe.45.1352863925553;
        Tue, 13 Nov 2012 19:32:05 -0800 (PST)
X-BeenThere: chromium-revi...@chromium.org
Received: by 10.236.149.73 with SMTP id w49ls33601yhj.5.gmail; Tue, 13 Nov
 2012 19:32:04 -0800 (PST)
Received: by 10.236.87.77 with SMTP id x53mr25507345yhe.7.1352863924305;
        Tue, 13 Nov 2012 19:32:04 -0800 (PST)
Received: by 10.236.87.77 with SMTP id x53mr25507344yhe.7.1352863924290;
        Tue, 13 Nov 2012 19:32:04 -0800 (PST)
Return-Path: <3tBCjUBUJAOsPUebZVhZPbQReRiVRj-UeTZNVY....@2uix4h7xygsz66weerlq.apphosting.bounces.google.com>
Received: from mail-ye0-f198.google.com (mail-ye0-f198.google.com [209.85.213.198])
        by mx.google.com with ESMTPS id f45si10132662yhg.38.2012.11.13.19.32.04
        (version=TLSv1/SSLv3 cipher=OTHER);
        Tue, 13 Nov 2012 19:32:04 -0800 (PST)
Received-SPF: pass (google.com: domain of 3tBCjUBUJAOsPUebZVhZPbQReRiVRj-UeTZNVY....@2uix4h7xygsz66weerlq.apphosting.bounces.google.com designates 209.85.213.198 as permitted sender) client-ip=209.85.213.198;
Authentication-Results: mx.google.com; spf=pass (google.com: domain of 3tBCjUBUJAOsPUebZVhZPbQReRiVRj-UeTZNVY....@2uix4h7xygsz66weerlq.apphosting.bounces.google.com designates 209.85.213.198 as permitted sender) smtp.mail=3tBCjUBUJAOsPUebZVhZPbQReRiVRj-UeTZNVY....@2uix4h7xygsz66weerlq.apphosting.bounces.google.com; dkim=pass header...@chromium.org
Received: by mail-ye0-f198.google.com with SMTP id m9so1677530yen.5
        for <chromium-revi...@chromium.org>; Tue, 13 Nov 2012 19:32:04 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=chromium.org; s=google;
        h=mime-version:reply-to:x-google-appengine-app-id:message-id:date
         :subject:from:to:cc:content-type;
        bh=A4T2dNW2F9wBc27xMa5GQGNauGpSNc3s+02Cn7QSKKg=;
        b=QbW1Jl2cyd2mwpFYfzVo/KTIWo5b8sFsNxhycHUlf63lb56C1wbP8UWtFwLnNABPfO
         YxGv5UvHf0n2pz0rOkoQcxgzG3YX/xE3TS3PqnzGLWGdE9/mfWAQX9MuAiWkozRZ7RF8
         LYb71maseLKWlYWyfrlrk1OY8Dar4uxLTZh+g=
MIME-Version: 1.0
Received: by 10.58.247.39 with SMTP id yb7mr7787970vec.24.1352863924148; Tue,
 13 Nov 2012 19:32:04 -0800 (PST)
Reply-To: victorhs...@chromium.org, bre...@chromium.org, c...@chromium.org, 
	chromium-revi...@chromium.org, joi+watch-cont...@chromium.org, 
	darin...@chromium.org, j...@chromium.org
Message-ID: <047d7b6d9202a0db3104ce6c2...@google.com>
Date: Wed, 14 Nov 2012 03:32:04 +0000
Subject: Re: Migrate Graphics2D to new design. (issue 11053003)
From: c...@chromium.org
To: victorhs...@chromium.org, bre...@chromium.org
Cc: chromium-revi...@chromium.org, joi+watch-cont...@chromium.org, 
	darin...@chromium.org, j...@chromium.org
Content-Type: text/plain; charset=ISO-8859-1; format=flowed; delsp=yes

On 2012/11/14 02:25:51, Victor Hsieh wrote:

https://codereview.chromium.org/11053003/diff/81096/ppapi/proxy/graphics_2d_resource.cc
> File ppapi/proxy/graphics_2d_resource.cc (right):


https://codereview.chromium.org/11053003/diff/81096/ppapi/proxy/graphics_2d_resource.cc#newcode36
> ppapi/proxy/graphics_2d_resource.cc:36: std::numeric_limits<int32>::max();
> On 2012/11/14 02:03:46, Cris Neckar wrote:
> > when width * height * 4 wraps the 64 bit integer this check will pass.  
> Seems
> > like you would either need to do an unsigned comparison or check for a
> negative
> > result.

> I think the int32 max will be promoted to int64 when comparing, so we  
> don't
need
> to worry about overflow.
That's correct it will be promoted to a signed 64 bit into but will wrap to
causing the check to pass.


https://codereview.chromium.org/11053003/