chiark / gitweb /
ptyfwd: Set the size of the PTY base on the size of stdout, not stdin.
[elogind.git] / src / nspawn / nspawn.c
index eef0e9a28147012fb810a25d4b0a0f7e6fc54e64..583912f57c51bb3c0b40c7646896c69c5e374ffb 100644 (file)
@@ -1096,7 +1096,7 @@ int main(int argc, char *argv[]) {
         path_kill_slashes(arg_directory);
 
         if (!arg_machine) {
-                arg_machine = strdup(path_get_file_name(arg_directory));
+                arg_machine = strdup(basename(arg_directory));
                 if (!arg_machine) {
                         log_oom();
                         goto finish;