From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2607:f8b0:4001:c0b::243; helo=mail-it0-x243.google.com; envelope-from=ard.biesheuvel@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-it0-x243.google.com (mail-it0-x243.google.com [IPv6:2607:f8b0:4001:c0b::243]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id B5258223230D0 for ; Fri, 16 Feb 2018 03:22:33 -0800 (PST) Received: by mail-it0-x243.google.com with SMTP id j21so3509814ita.1 for ; Fri, 16 Feb 2018 03:28:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=p8HYjbqVi/f5TLbz5VN5fbRTavWA0bPEXp8Qgc6gF4w=; b=cD1rspf//EqmDGNdC+UHQgrS+iI8Fmkd1lCO+wMsWAx7Nyws21NVUOhHVxgfVMvKrO 396CXtNGA5wj2yZ03wtMrFhkPWlA1McxhEi5nTVzmSHY6GgljFgOQb01L8lRUvkpcPj7 MT9964awVbJbFD2uJjmq866zvYVeOnLr3OAQ0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=p8HYjbqVi/f5TLbz5VN5fbRTavWA0bPEXp8Qgc6gF4w=; b=J4MkBxn+SHt33d+BYjN17hnCtBkBNF+pkNlurxQbPIucn1sfW+/W5yOCz9mM8tLmTZ OE69ZJvOtWXsJiu9q39PpY+pfD3HuULJd+BFnuLCRAjZUl6rJA1LcIbga86v3eKeMmZa YjcKnICWn9nLvZX9A1Qy4bWqH79b9aYL2PzZK0RSaIRYQZUwwBtRyttL5i89uucQWgfW TDa+39xmlJFZx+aF4W0XUF4CuxMlQ5hO83Zry4/ErQzOV2K0K+/K77hVKlMSJ6H2431s AvcsMSR9p3j0YxVAdRw8uadPvDz4m6Ms7s1mjppjT6UQGORrwMh8w3L74gMuHNGZtVob wkog== X-Gm-Message-State: APf1xPDrtc0g332yr38RM+PbQW77aOL+dSfCvgvW0xmUk1LlHjB0o2IA 2/3tOQqN0nIpxG0Sh+Wq72I/emTCGLBfxsqFWfh16Q== X-Google-Smtp-Source: AH8x227SZInODOy0itr/y4r5QmqAizCcPqylOLxkbcqd2IHTM2SaVRlyfGw654sb5YpD8VytlrKpspnWdJ1qP0s1Tq8= X-Received: by 10.36.172.10 with SMTP id s10mr7546693ite.42.1518780506217; Fri, 16 Feb 2018 03:28:26 -0800 (PST) MIME-Version: 1.0 Received: by 10.107.138.209 with HTTP; Fri, 16 Feb 2018 03:28:25 -0800 (PST) In-Reply-To: <20180215183638.18578-1-lersek@redhat.com> References: <20180215183638.18578-1-lersek@redhat.com> From: Ard Biesheuvel Date: Fri, 16 Feb 2018 11:28:25 +0000 Message-ID: To: Laszlo Ersek Cc: edk2-devel-01 , Michael D Kinney , Liming Gao Subject: Re: [PATCH 0/4] MdePkg/BaseSafeIntLib: fix undefined behavior in INT64 Sub/Add/Mult X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Feb 2018 11:22:34 -0000 Content-Type: text/plain; charset="UTF-8" On 15 February 2018 at 18:36, Laszlo Ersek wrote: > Repo: https://github.com/lersek/edk2.git > Branch: signed_range_checks > > Based on the discussion starting at > . > > Cc: Bret Barkelew > Cc: Liming Gao > Cc: Michael D Kinney > Cc: Sean Brogan > > Laszlo Ersek (4): > MdePkg/BaseSafeIntLib: fix undefined behavior in SafeInt64Sub() > MdePkg/BaseSafeIntLib: fix undefined behavior in SafeInt64Add() > MdePkg/BaseSafeIntLib: clean up parentheses in MIN_INT64_MAGNITUDE > MdePkg/BaseSafeIntLib: fix undefined behavior in SafeInt64Mult() > > MdePkg/Library/BaseSafeIntLib/SafeIntLib.c | 110 ++++++++++++++++---- > 1 file changed, 88 insertions(+), 22 deletions(-) > Hello Laszlo, Thanks a lot for taking the time to fix this library. I am not a C scholar, but I have reviewed these patches to the best of my abilities. Reviewed-by: Ard Biesheuvel I take it we don't need to add -fwrapv now? Thanks again, Ard.