[Kde-imaging] [Bug 308465] New: TimeAdjust cannot change file modification timestamp for files with non-ASCII characters in path
Karol Slanina
karol.slanina at gmail.com
Mon Oct 15 22:51:36 UTC 2012
https://bugs.kde.org/show_bug.cgi?id=308465
Bug ID: 308465
Severity: normal
Version: 2.9.0
Priority: NOR
Assignee: kde-imaging at kde.org
Summary: TimeAdjust cannot change file modification timestamp
for files with non-ASCII characters in path
Classification: Unclassified
OS: Linux
Reporter: karol.slanina at gmail.com
Hardware: Archlinux Packages
Status: UNCONFIRMED
Component: TimeAdjust
Product: kipiplugins
TimeAdjust is not able to change the file modification timestamps in case that
the filesystem uses UTF-8 (or any non-ASCII or non-Latin1 encoding) and there's
a file that has a non-ASCII character in its path. Timestamps for ASCII-only
files can be successfully processed though. This bug does not affect timestamps
in metadata such as EXIF, IPTC or XMP, which can be successfully modified for
all files regardless of the characters in their names.
Reproducible: Always
Steps to Reproduce:
1. Create an image with a non-ASCII character in its name or path, e.g.
"Besançon.jpg" or "Kraków.jpg"
2. Try to modify its file last modified timestamp via the TimeAdjust plugin
Actual Results:
Files with non-ASCII characters cannot be processed (Status = "Failed to update
file timestamp"), while files with ASCII only characters are updated
successfully (Status = "Processed without error")
Expected Results:
All files are processed successfully
TimeAdjust plugin assumes that all characters in the file path are encoded with
Latin1 encoding:
if (utime(m_url.path().toLatin1().constData(), ×) != 0)
Instead of calling m_url.path().toLatin1().constData(), the conversion to const
char* should be done by
QFile::encodeName(m_url.toLocalFile()).constData()
which respects the user's locale.
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the Kde-imaging
mailing list