From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752208AbcF0U20 (ORCPT ); Mon, 27 Jun 2016 16:28:26 -0400 Received: from mx2.suse.de ([195.135.220.15]:34069 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751857AbcF0U2Z (ORCPT ); Mon, 27 Jun 2016 16:28:25 -0400 Date: Mon, 27 Jun 2016 22:28:23 +0200 Message-ID: From: Takashi Iwai To: "Christophe JAILLET" Cc: , , , Subject: Re: [PATCH] ALSA: echoaudio: Fix memory allocation In-Reply-To: <1467054411-19752-1-git-send-email-christophe.jaillet@wanadoo.fr> References: <1467054411-19752-1-git-send-email-christophe.jaillet@wanadoo.fr> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 Emacs/24.5 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 27 Jun 2016 21:06:51 +0200, Christophe JAILLET wrote: > > 'commpage_bak' is allocated with 'sizeof(struct echoaudio)' bytes. > We then copy 'sizeof(struct comm_page)' bytes in it. > On my system, smatch complains because one is 2960 and the other is 3072. > > This would result in memory corruption or a oops. > > Signed-off-by: Christophe JAILLET Applied, thanks. Takashi