eliminate double quotes in open's path argument

modify the sprintpath() to detect the jflag.
this is just a workaround and should change later.