dd segfaults in some locales
Bug #73571 reported by
Fredrik Arnerup
This bug report is a duplicate of:
Bug #42264: language pack po files drop cflag comment which causes segfaults in e. g. 'dd'.
Edit
Remove
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
coreutils (Ubuntu) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: coreutils
dd (coreutils 5.93-5) segfaults after copying more than one byte if not using the "C" locale:
$ LC_ALL=C dd if=/dev/zero of=/dev/null bs=1024 count=16
16+0 records in
16+0 records out
16384 bytes (16 kB) copied, 3.5e-05 seconds, 468 MB/s
$ LC_ALL=en_US.UTF-8 dd if=/dev/zero of=/dev/null bs=1024 count=16
16+0 records in
16+0 records out
Segmentation fault
It might have something to do with UTF-8
It seems to do the job before it segfaults, though
To post a comment you must log in.
Correction: "??_??. UTF-8" with LANGUAGE=sv.
It only segfaults for me if I combine LC_ALL=
$ LC_ALL=en_US.UTF-8 LANGUAGE=sv dd if=/dev/zero of=/dev/null bs=1 count=2
2+0 records in
2+0 records out
Segmentation fault
$ LC_ALL=C LANGUAGE=sv dd if=/dev/zero of=/dev/null bs=1 count=2 2+0 records in
2+0 records out
2 bytes (2 B) copied, 2.3e-05 seconds, 87.0 kB/s
$ LC_ALL=en_US.UTF-8 LANGUAGE=en dd if=/dev/zero of=/dev/null bs=1 count=2
2+0 records in
2+0 records out
2 bytes (2 B) copied, 2.6e-05 seconds, 76.9 kB/s
Copying a single byte also works:
$ LC_ALL=en_US.UTF-8 LANGUAGE=sv dd if=/dev/zero of=/dev/null bs=1 count=1
1+0 records in
1+0 records out
1 byte (1 B) kopierad, 2.6e-05 sekunder, 38.5 kB/s