From: Graham C. <g+o...@co...> - 2013-09-18 19:26:32
|
On 18/09/13 13:25, Mark Ellis wrote: > Actually, I was thinking about what Graham said initially, and it's left > me in a dilemma. Oops, sorry about that, Mark. Given the effort you are putting in on Opensync, I really don't want to slow you down! > Using the glib function, with Graham's additional allowed characters, is > nice, easy, quick and safe, but as Graham said, does limit users in what > they can call new files they want to sync. I've written an alternative > which only escapes %/:*\\>< but it assumes everything is utf8 and/or > ascii. > > So my response is, would we rather have something easy with a bit less > functionality, or more functionality with built in assumptions that > might have unforeseen consequences ? I am happy with either. If you are happy with the allowed characters I suggested then I am happy with those constraints. I think I covered the most likely ones people will use, except for : but we don't have much choice about that as it is invalid under Windows. I am also happy with the utf8 assumption, but you may be right to be cautious. Bottom line: whichever you prefer. My vote is go for the glib function with a fairly permissive list of allowed characters and don't worry about the other cases. Thanks for taking the time to think about this and sorry for holding you up so much. Graham |