! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Mounting network location doesn't open location in view
Status:
RESOLVED: FIXED

Comments

Description Harald Judt 2012-11-03 21:24:21 CET
This needs a bookmarked network resource in the shortcut pane, e.g. "sftp://user@server/some/dir dir" in .gtk-bookmarks

Steps to reproduce:

1) Click on the shortcut to mount the resource.
2) A password dialog is opened.
3) Enter the correct password.

Expected results:
The remote resource is opened.

Actual results:
The remote resource is mounted, but not opened in the view. You have to click on the shortcut again.

I've started doing a little trace:

Wrong flow (performing steps 1-3 described above):
thunar_browser_poke_location called.
        calling thunar_browser_poke_file_data_new
        returned from thunar_browser_poke_file_data_new
        calling thunar_file_get_async with poke_data
thunar_file_get_async called.
        load file information asynchronously.
        g_file_query_info_async called.
thunar_file_get_async exit.
        returned from thunar_file_get_async
thunar_browser_poke_location exit.
thunar_shortcuts_view_open exit.
thunar_file_get_async called.
        calling query_info_finish.
        returned from query_info_finish.
        resetting file.
        file info reload.
        passing loaded file and possible errors to the return function.
        data->func = 0x426380
        returned from return function.
thunar_file_get_async exit.

Correct flow (clicking on the shortcut, like described in actual results):
thunar_shortcuts_view_open called.
        determining file for shortcut.
                location != NULL, poking location.
thunar_browser_poke_location called.
        calling thunar_browser_poke_file_data_new
        returned from thunar_browser_poke_file_data_new
        calling thunar_file_get_async with poke_data
thunar_file_get_async called.
        load file information asynchronously.
        g_file_query_info_async called.
thunar_file_get_async exit.
        returned from thunar_file_get_async
thunar_browser_poke_location exit.
thunar_shortcuts_view_open exit.
thunar_file_get_async called.
        calling query_info_finish.
        returned from query_info_finish.
        resetting file.
        file info reload.
        passing loaded file and possible errors to the return function.
        data->func = 0x426380
thunar_shortcuts_view_poke_location_finish called.
        No errors, calling poke_file_finish
thunar_shortcuts_view_poke_file_finish called.
        Emitting ready signal to show in current view.
        No errors, returned from poke_file_finish
thunar_shortcuts_view_poke_location_finish exit.
        returned from return function.
thunar_file_get_async exit.

(Some debug code would really help for tracing such problems...)

If my understanding is right then that pointer data->func points to the same function, which should be view_poke_location_finish. Yet for some reason that function does not seem to be called in the first trace, because it would have caused a few more messages to appear like in the second trace (the 'function called' messages are placed before any return_if_fail).

I assume that call should happen in thunar_file_get_async_finish:
    (data->func) (location, file, error, data->user_data);
Comment 1 Nick Schermer editbugs 2012-11-03 21:38:26 CET
Not only with a password. Happens without too.
Comment 2 Harald Judt 2012-11-04 11:08:22 CET
I see. I was a bit mistaken with that gpointer "data->func = 0x426380" value. Of course it's entirely possible that a different function gets called, so nothing unusual here. I'm quite sure (data->func) (location, file, error, data->user_data) calls a different function. The question now is where do the original values get lost, and maybe what is called instead of thunar_shortcuts_view_poke_location_finish? All in all, very confusing...
Comment 3 Harald Judt 2012-11-05 11:16:16 CET
Without having done any further analysis: Can this be because the shortcut pane updates during this process? With updating I mean a new entry with an eject button is shown for the network mount.

Also, a bookmark created for the root folder of the sftp mount (named "/ on host") doesn't behave correctly. The network mount will be selected instead of the bookmark when you click on the bookmark, and renaming - while clickable in the context menu - is not possible unless you close and reopen the window. Not that renaming would make any difference.
Comment 4 Nick Schermer editbugs 2012-11-08 20:38:19 CET
Fixed.
Comment 5 Harald Judt 2012-11-10 10:07:11 CET
Thanks, works great now!

Bug #9447

Reported by:
Harald Judt
Reported on: 2012-11-03
Last modified on: 2012-11-10

People

Assignee:
Jannis Pohlmann
CC List:
1 user

Version

Attachments

Additional information