[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [gftp] Re: Changing Novell servers with CWD //server



Michal Schmidt wrote:
  [...]
  Now I've added several printf()s into the source to find out, where
the double slashes get removed. I've found this:
In ./src/gtk/menu-items.c:chdir_edit: edttxt=//dzin
In ./lib/misc.c:expand_path: src=//dzin
In ./lib/misc.c:expand_path: newstr=/dzin
In ./src/gtk/menu-items.c:chdir_edit: tempstr=/dzin

So the function expand_path removes the slash. I am now trying to
understand, what exactly this function is supposed to do. I may then be
able to fix it myself.
OK, here's my quick&dirty solution. I've commented out the call to expand_path in src/gtk/menu-items.c and replaced it with:

tempstr=g_strdup(edttxt);

It now seems to work reasonably well. Here is how it looks after successful login:

230 User xschmi00 Logged in Successfully
SYST
215 NETWARE Type : L8
TYPE I
200 TYPE Command OK I
PWD
257 "/usr/stud/xschmi00" is Current Directory
PASV
227 Entering Passive Mode (147,229,14,96,95,101)
LIST -a
150 Opening data connection
226 Transfer Complete

Now I type "//dzin" into the remote directory combobox:

CWD //dzin
250 Directory successfully changed to "/"
PASV
227 Entering Passive Mode (147,229,14,96,95,102)
LIST -a
150 Opening data connection
226 Transfer Complete

Now I can see the correct directory listing on the server DZIN. One of the directories is called APP. I try to enter it by doubleclicking on it:

CWD /dzin/APP
550 Invalid Path

So that didn't work because gFTP got confused about the current directory. So I type "/" into the combobox:

CWD /
250 Directory successfully changed to "/"
PASV
227 Entering Passive Mode (147,229,14,96,95,103)
LIST -a
150 Opening data connection
226 Transfer Complete

I'm still in the same "/" directory on DZIN but this time gFTP understands this and doubleclicking on the APP directory works as expected:

CWD /APP
250 Directory successfully changed to "/app/"
PASV
227 Entering Passive Mode (147,229,14,96,95,104)
LIST -a
150 Opening data connection
226 Transfer Complete

So the my solution isn't perfect but it allows me to access all the Novell servers.

Michal Schmidt