public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/5903] New: "iconv" creates unnecessary output
@ 2008-03-10 12:58 titcouille dot mandriva at gmail dot com
2008-03-10 21:18 ` [Bug libc/5903] " rsa at us dot ibm dot com
2008-03-11 20:14 ` drepper at redhat dot com
0 siblings, 2 replies; 4+ messages in thread
From: titcouille dot mandriva at gmail dot com @ 2008-03-10 12:58 UTC (permalink / raw)
To: glibc-bugs
This bug concerns the "iconv" utility. It's not really a bug, but bad design. I did:
iconv --from-code==LATIN1 --to-code=UTF-8 --output=file_to_convert.xml
output_file.xml
where mistakingly I had put my original file, file_to_convert.xml, as output
file. And for source file I had specified mistakingly some output filename which
doesn't exist. So iconv displayed that "output_file.xml" doesn't exist, that it
can't read from it, but replaced my original file (file_to_convert.xml) with an
empty 0-byte file. But it's stupid that it would put an empty file (and thus
destroy all my data) when there was nothing to convert in the first place.
To sum it up, don't create an output file when there isn't an input file.
--
Summary: "iconv" creates unnecessary output
Product: glibc
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: libc
AssignedTo: drepper at redhat dot com
ReportedBy: titcouille dot mandriva at gmail dot com
CC: glibc-bugs at sources dot redhat dot com
http://sourceware.org/bugzilla/show_bug.cgi?id=5903
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libc/5903] "iconv" creates unnecessary output
2008-03-10 12:58 [Bug libc/5903] New: "iconv" creates unnecessary output titcouille dot mandriva at gmail dot com
@ 2008-03-10 21:18 ` rsa at us dot ibm dot com
2008-03-11 20:14 ` drepper at redhat dot com
1 sibling, 0 replies; 4+ messages in thread
From: rsa at us dot ibm dot com @ 2008-03-10 21:18 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From rsa at us dot ibm dot com 2008-03-10 21:17 -------
In libc/iconv/iconv_prog.c the output_file is fopen'ed prior to processing any
of the files specified on the command line.
Perhaps a lazy fopen() of the output_file can take place when an actual
fopen(argv[remaining]) succeeds.
I'll investigate.
--
What |Removed |Added
----------------------------------------------------------------------------
AssignedTo|drepper at redhat dot com |rsa at us dot ibm dot com
Status|NEW |ASSIGNED
http://sourceware.org/bugzilla/show_bug.cgi?id=5903
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libc/5903] "iconv" creates unnecessary output
2008-03-10 12:58 [Bug libc/5903] New: "iconv" creates unnecessary output titcouille dot mandriva at gmail dot com
2008-03-10 21:18 ` [Bug libc/5903] " rsa at us dot ibm dot com
@ 2008-03-11 20:14 ` drepper at redhat dot com
1 sibling, 0 replies; 4+ messages in thread
From: drepper at redhat dot com @ 2008-03-11 20:14 UTC (permalink / raw)
To: glibc-bugs
------- Additional Comments From drepper at redhat dot com 2008-03-11 20:13 -------
I checked in a patch to the trunk.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
http://sourceware.org/bugzilla/show_bug.cgi?id=5903
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libc/5903] "iconv" creates unnecessary output
[not found] <bug-5903-131@http.sourceware.org/bugzilla/>
@ 2014-07-02 6:14 ` fweimer at redhat dot com
0 siblings, 0 replies; 4+ messages in thread
From: fweimer at redhat dot com @ 2014-07-02 6:14 UTC (permalink / raw)
To: glibc-bugs
https://sourceware.org/bugzilla/show_bug.cgi?id=5903
Florian Weimer <fweimer at redhat dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Flags| |security-
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-07-02 6:14 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-10 12:58 [Bug libc/5903] New: "iconv" creates unnecessary output titcouille dot mandriva at gmail dot com
2008-03-10 21:18 ` [Bug libc/5903] " rsa at us dot ibm dot com
2008-03-11 20:14 ` drepper at redhat dot com
[not found] <bug-5903-131@http.sourceware.org/bugzilla/>
2014-07-02 6:14 ` fweimer at redhat dot com
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).