From patchwork Sun Mar 7 21:15:58 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ferenc Wagner X-Patchwork-Id: 47096 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [18.85.46.34]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id E2539B7CB6 for ; Mon, 8 Mar 2010 08:19:00 +1100 (EST) Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.69 #1 (Red Hat Linux)) id 1NoNq9-0005iV-MM; Sun, 07 Mar 2010 21:16:45 +0000 Received: from tac.ki.iif.hu ([2001:738:0:401:20c:6eff:fe71:b2db]) by bombadil.infradead.org with esmtps (Exim 4.69 #1 (Red Hat Linux)) id 1NoNpl-0005KZ-5C for linux-mtd@lists.infradead.org; Sun, 07 Mar 2010 21:16:21 +0000 Received: from wferi by tac.ki.iif.hu with local (Exim 4.69) (envelope-from ) id 1NoNpO-0007Dl-4c for linux-mtd@lists.infradead.org; Sun, 07 Mar 2010 22:15:58 +0100 From: Ferenc Wagner To: linux-mtd@lists.infradead.org Subject: [PATCH, mtd-utils] creat(2) expects a creation mode parameter, not an open flag Date: Sun, 07 Mar 2010 22:15:58 +0100 Message-ID: <87sk8bzvch.fsf@tac.ki.iif.hu> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) MIME-Version: 1.0 X-CRM114-Version: 20090807-BlameThorstenAndJenny ( TRE 0.7.6 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20100307_161621_446205_E1609D16 X-CRM114-Status: UNSURE ( 9.58 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.0 (/) X-Spam-Report: SpamAssassin version 3.2.5 on bombadil.infradead.org summary: Content analysis details: (-0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 NO_RELAYS Informational: message was not relayed via SMTP X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-mtd-bounces@lists.infradead.org Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org Signed-off-by: Ferenc Wagner --- mtd_debug.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/mtd_debug.c b/mtd_debug.c index 85d48e9..49a4567 100644 --- a/mtd_debug.c +++ b/mtd_debug.c @@ -110,7 +110,7 @@ int flash_to_file (int fd,u_int32_t offset,size_t len,const char *filename) perror ("lseek()"); goto err0; } - outfd = creat (filename,O_WRONLY); + outfd = creat (filename,0666); if (outfd < 0) { perror ("creat()");