Bug 267186 - Kompare cannot handle one-byte character sets
Summary: Kompare cannot handle one-byte character sets
Status: REPORTED
Alias: None
Product: kompare
Classification: Applications
Component: general (show other bugs)
Version: 4.1.22120
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Kompare developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-26 02:25 UTC by Christopher Yeleighton
Modified: 2023-01-04 11:19 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
source files and patches (391 bytes, application/x-gzip)
2011-02-26 02:25 UTC, Christopher Yeleighton
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christopher Yeleighton 2011-02-26 02:25:34 UTC
Created attachment 57535 [details]
source files and patches

Version:           4.0.0 (using KDE 4.6.0) 
OS:                Linux

When the original files are in one-byte character sets, the patch produced by Kompare fails.

Reproducible: Always

Steps to Reproduce:
  1. 
Tell Kompare to save the difference between la1.txt and utf8.txt into Kompare.diff.

  2. { patch <Kompare.diff; }

Actual Results:  
  2. 
patching file la1.txt
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED -- saving rejects to file la1.txt.rej

Expected Results:  
  2.  Clean patch.

OS: Linux (x86_64) release 2.6.34.7-0.7-desktop
Compiler: gcc
Comment 1 Christopher Yeleighton 2011-02-26 02:32:54 UTC
Note: this bug makes Kompare absolutely useless for generating patches because you can never be sure whether such a patch can be successfully applied until you try (source code files often contain accented characters in comments as ISO Latin 1).  Kompare does not try to adapt to this reality; it does not even emit a warning.
Comment 2 Kevin Kofler 2011-02-26 03:07:00 UTC
You have to change the character set. The default is UTF-8.

(FWIW, source files which are still in Latin 1 really need to be fixed. Those Latin 1 characters will also be clobbered when edited with a modern editor which defaults to UTF-8.)
Comment 3 Christopher Yeleighton 2012-08-04 20:47:12 UTC
(In reply to comment #2)
> You have to change the character set. The default is UTF-8.
> 
> (FWIW, source files which are still in Latin 1 really need to be fixed.
> Those Latin 1 characters will also be clobbered when edited with a modern
> editor which defaults to UTF-8.)

A "modern" editor that clobbers Latin 1 characters because the default is UTF–8 (like e.g. Microsoft Web Developer, shame on them) is just dumb, my good sir.  (Fortunately, KWrite does not subscribe to your POV on this subject any more.)
Comment 4 Andrew Crouthamel 2018-11-09 01:01:46 UTC
Dear Bug Submitter,

This bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version? I am setting the status to NEEDSINFO pending your response, please change the Status back to REPORTED when you respond.

Thank you for helping us make KDE software even better for everyone!
Comment 5 Andrew Crouthamel 2018-11-18 03:30:20 UTC
Dear Bug Submitter,

This is a reminder that this bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version? This bug will be moved back to REPORTED Status for manual review later, which may take a while. If you are able to, please lend us a hand.

Thank you for helping us make KDE software even better for everyone!
Comment 6 Justin Zobel 2022-12-20 22:51:46 UTC
Thank you for reporting this issue in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version?

If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Comment 7 Bug Janitor Service 2023-01-04 05:25:11 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 8 Christopher Yeleighton 2023-01-04 11:19:28 UTC
Comparing la1.txt and utf8.txt returns no differences now (even though they are different according to command line diff).