From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32763 invoked by alias); 6 Aug 2002 08:10:23 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 32751 invoked from network); 6 Aug 2002 08:10:22 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sources.redhat.com with SMTP; 6 Aug 2002 08:10:22 -0000 Received: from int-mx2.corp.redhat.com (nat-pool-rdu.redhat.com [172.16.52.200] (may be forged)) by mx1.redhat.com (8.11.6/8.11.6) with ESMTP id g767vTl29723 for ; Tue, 6 Aug 2002 03:57:29 -0400 Received: from potter.sfbay.redhat.com (potter.sfbay.redhat.com [172.16.27.15]) by int-mx2.corp.redhat.com (8.11.6/8.11.6) with ESMTP id g768ALu10357 for ; Tue, 6 Aug 2002 04:10:21 -0400 Received: from cygbert.vinschen.de (vpn50-20.rdu.redhat.com [172.16.50.20]) by potter.sfbay.redhat.com (8.11.6/8.11.6) with ESMTP id g768AJe02077 for ; Tue, 6 Aug 2002 01:10:20 -0700 Received: (from corinna@localhost) by cygbert.vinschen.de (8.11.6/8.9.3/Linux sendmail 8.9.3) id g768AHN26319 for gdb-patches@sources.redhat.com; Tue, 6 Aug 2002 10:10:17 +0200 Date: Tue, 06 Aug 2002 01:10:00 -0000 From: Corinna Vinschen To: gdb-patches@sources.redhat.com Subject: Re: [RFA] cli/cli-dump.c: Write dump always in binary mode on Cygwin Message-ID: <20020806101017.Q3921@cygbert.vinschen.de> Reply-To: gdb-patches@sources.redhat.com Mail-Followup-To: gdb-patches@sources.redhat.com References: <3D4F0170.65B5B543@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.3.22.1i X-SW-Source: 2002-08/txt/msg00120.txt.bz2 On Tue, Aug 06, 2002 at 07:42:47AM +0300, Eli Zaretskii wrote: > > On Mon, 5 Aug 2002, Michael Snyder wrote: > > > do we actually know of any environments > > where the #if is strictly necessary? > > Since GDB requires ISO C, and "wb" is part of the ISO C spec, I think we > can drop the #if. (Dependance on O_BINARY being defined is not very > clean anyway, IMHO, since O_BINARY does not belong to `fopen'.) Well, that changes the patch to: 2002-08-06 Corinna Vinschen * cli/cli-dump.c (add_dump_command): Explicitely use "b" flag to write dump file binary. Index: cli/cli-dump.c =================================================================== RCS file: /cvs/src/src/gdb/cli/cli-dump.c,v retrieving revision 1.4 diff -u -p -r1.4 cli-dump.c --- cli/cli-dump.c 24 May 2002 01:25:52 -0000 1.4 +++ cli/cli-dump.c 6 Aug 2002 08:08:27 -0000 @@ -442,7 +442,7 @@ add_dump_command (char *name, void (*fun c->completer = filename_completer; d = XMALLOC (struct dump_context); d->func = func; - d->mode = "w"; + d->mode = "wb"; set_cmd_context (c, d); c->func = call_dump_func; @@ -450,7 +450,7 @@ add_dump_command (char *name, void (*fun c->completer = filename_completer; d = XMALLOC (struct dump_context); d->func = func; - d->mode = "a"; + d->mode = "ab"; set_cmd_context (c, d); c->func = call_dump_func; Is that ok? Corinna -- Corinna Vinschen Cygwin Developer Red Hat, Inc. mailto:vinschen@redhat.com