After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 675591 - Errors due to non-Latin letters in the name of the user profile
Errors due to non-Latin letters in the name of the user profile
Status: RESOLVED FIXED
Product: GEGL
Classification: Other
Component: general
git master
Other Windows
: Normal major
: ---
Assigned To: Default Gegl Component Owner
Default Gegl Component Owner
: 707279 751175 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2012-05-07 08:22 UTC by K.V.
Modified: 2015-06-19 18:15 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description K.V. 2012-05-07 08:22:43 UTC
The application closes with an error: "This application has requested the Runtime to terminate it in an unusual way" when "Cage Transfrom" apply, when i close the contour. This happens if user profile name has non-latin letters (cyrillic for exapmle).
The same error occurs with "View->Use GEGL" command, when image editing
Comment 1 billy_kid 2012-05-16 19:07:06 UTC
I have got the same trouble with Gimp 2.8.0. I am French and there's the letter 'é' in my Windows username. I tried to create another user and this time, it was ok.
Sorry for my poor English!
Comment 2 Michael Natterer 2012-05-16 20:07:54 UTC
We need somebody with a debugger to tell us where exactly the error happens,
otherwise we can do nothing.
Comment 3 Massimo 2012-05-17 10:44:15 UTC
GEGL is not using 'g_open' and friends from <glib/gstdio.h>

in GEGL sources root

grep '[^a-zA-Z0-9_]g_open *(' gegl/{*/,}*.c

but
grep '[^a-zA-Z0-9_]open *(' gegl/{*/,}*.c

gegl/buffer/gegl-buffer-load.c:  info->i = open (info->path, O_RDONLY);
gegl/buffer/gegl-buffer-save.c:  info->o    = open (info->path, O_RDWR|O_CREAT|O_TRUNC, S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH);
gegl/buffer/gegl-buffer-save.c:  info->o    = open (info->path, O_RDWR|O_CREAT|O_TRUNC, S_IRUSR|S_IWUSR);
gegl/buffer/gegl-tile-backend-file.c:      self->o = open (self->path, O_RDWR|O_CREAT, 0770);
gegl/buffer/gegl-tile-backend-file.c:          self->o = open (self->path, O_RDONLY, 0770);
gegl/buffer/gegl-tile-backend-file.c:      self->o = open (self->path, O_RDWR|O_CREAT, 0770);

I'm not an expert, but I think there are combinations of utf8 path
names, system code pages etc. for which using libc 'open' fails on
Windows.

I don't know whether that code is executed or not with cage tool or
View->Use GEGL, but it will likely be when GeglBuffer will replace
TileManager, and since the swapdir is under user_cache_dir...
Comment 4 Massimo 2012-05-18 05:15:02 UTC
Confirming: after creating a User 'généviève', running GIMP from a DOS prompt

"%ProgramFiles%\GIMP 2\bin\gimp-2.8" --verbose 2>out.txt

selecting View->Use GEGL or using the cage tool makes crash GIMP on an
assertion failure in GEGL:


(gimp-2.8:568): GEGL-gegl-tile-backend-file.c-WARNING **: gegl_tile_backend_file_ensure_exist: Could not open 'C:\Users\génèviève\AppData\Local\Microsoft\Windows\Temporary Internet Files\gegl-0.2\swap\568-3': No such file or directory

(gimp-2.8:568): GEGL-gegl-tile-backend-file.c-WARNING **: unable to seek in buffer
**
GEGL-gegl-tile-backend-file.c:ERROR:gegl-tile-backend-file.c:957:gegl_tile_backend_file_ensure_exist: assertion failed: (self->i != -1)

(script-fu.exe:3888): LibGimpBase-WARNING **: script-fu.exe: gimp_wire_read(): error


After changing 'open' to 'g_open' (and 'access' to 'g_access') and 
recompiling, repeating the same steps does not crash GIMP
Comment 5 Massimo 2012-05-18 15:36:08 UTC
Fixed in GEGL master.

commit 48c1d6ac8925c8b015748c2a445268ddad842d3b
Author: Massimo Valentini <mvalentini@src.gnome.org>
Date:   Fri May 18 15:02:19 2012 +0200

    gegl/buffer: use g_open,g_access instead of open,access
    
    Bug 675591: Errors due to non-Latin letters in the name
    of the user profile.
Comment 6 Massimo 2013-04-24 19:07:17 UTC
*** Bug 698688 has been marked as a duplicate of this bug. ***
Comment 7 F Champigneul 2013-04-24 22:30:10 UTC
One thing that could be useful for other people experiencing this bug, while the fixed GIMP & GEGL versions are not yet released, is that a workaround exists.
The workaround is to type the following three lines in a DOS window for starting GIMP (the first line is not compulsory):

cd %USERPROFILE%
SET GEGL_SWAP=RAM
"%ProgramFiles%\GIMP 2\bin\gimp-2.8.exe"

I have put this in a .bat file which I now use for launching GIMP.
Comment 8 Juan 2013-09-02 16:44:48 UTC
This is the solution for the problem, thanks!!!
Comment 9 Michael Schumacher 2013-10-11 19:20:50 UTC
*** Bug 707279 has been marked as a duplicate of this bug. ***
Comment 10 thewrewk szultán 2015-04-22 17:19:31 UTC
Thank you very much indeed, Massimo,  for your diagnosis. Since the workaround in question seems to be  mostly in Chinese for me, I've done what billy_kid did  3 years ago. A new user account has been created with no silly Hungarian characters like é, ö, ü, etc., and it has worked. God save nations using non ASCII characters.
Comment 11 Massimo 2015-06-19 18:15:09 UTC
*** Bug 751175 has been marked as a duplicate of this bug. ***