From: D M German <dmg@uv...> - 2013-09-05 00:49:26
I found an interesting bug in moving files from windows to Linux. It
has to do with having a .xoj file that refers to a PDF.
glib Unix's is not OS sensitive.
This code is run under Linux:
printf("Directory name in windows [%s] with basename [%s] in directory [%s]\n",
testWin, g_path_get_basename(testWin), g_path_get_dirname(testWin));
Directory name from Windows [C:\Users\dmg\Dropbox\0\rm-foss-coordination-diff.pdf]
in directory [.]
basically, Unix's glib's g_path_get_basename, g_path_get_dirname are only
capable of parsing Unix filenames, and can't parse the windows ones.
But interestingly, Window's glib is capable of properly splitting Linux
full (and windows' ones): filenames (this code is run under windows):
printf("Directory name in linux [%s] with basename [%s] in directory [%s]\n",
testLinux, g_path_get_basename(testLinux), g_path_get_dirname(testLinux));
Directory name from linux [/home/dmg/Dropbox] parsed as:
basename [Dropbox] in directory [/home/dmg]
Daniel M. German "In science, read, by preference,
the newest works; in literature,
Georges Leclerc Buffon -> the oldest."
dmg (at) uvic (dot) ca
replace (at) with @ and (dot) with .
Get latest updates about Open Source Projects, Conferences and News.