Skip to content
This repository has been archived by the owner on Jan 28, 2024. It is now read-only.

Commit

Permalink
Creating a new cookie and mounting it into the container does not wor…
Browse files Browse the repository at this point in the history
…k too
  • Loading branch information
marbetschar committed May 28, 2020
1 parent d6db5f7 commit f8d0e12
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Widgets/ContainerListBox.vala
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,9 @@ public class Tins.Widgets.ContainerListBox : Gtk.ListBox {
work_dir.make_directory_with_parents ();
}

var xauth_cookie_file = File.new_for_path (home_dir_path + "/.Xauthority");
var xauth_cookie_file = File.new_for_path (work_dir_path + "/.Xauthority");

/*// Create X auth cookie for secure authentication:
// Create X auth cookie for secure authentication:
string mcookie_stdout, mcookie_stderr;
int mcookie_exit_status;

Expand All @@ -213,7 +213,7 @@ public class Tins.Widgets.ContainerListBox : Gtk.ListBox {
throw new TinsError.MCOOKIE (mcookie_stderr);
}

string xauth_command_line = @"xauth -v -i -f '$(xauth_file.get_path())' add :$xserver_envp_display_number . '$mcookie_stdout'";
string xauth_command_line = @"xauth -v -i -f '$(xauth_cookie_file.get_path())' add :$host_xserver_envp_display_number . '$mcookie_stdout'";
string xauth_stdout, xauth_stderr;
int xauth_exit_status;
Process.spawn_command_line_sync (
Expand All @@ -225,7 +225,7 @@ public class Tins.Widgets.ContainerListBox : Gtk.ListBox {

if (xauth_exit_status != 0) {
throw new TinsError.XAUTH (xauth_stderr + "\n" + _("Command failed:") + " " + xauth_command_line);
}*/
}

string[] host_xserver_envp = {};
host_xserver_envp = Environ.set_variable (host_xserver_envp, "DISPLAY", @":$host_xserver_envp_display_number", true);
Expand Down

0 comments on commit f8d0e12

Please sign in to comment.