Skip to content

Commit 215003a

Browse files
committed
fix when no hostenv
1 parent f38b304 commit 215003a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ fn run_file(vm: &VirtualMachine, scope: Scope, path: &str) -> PyResult<()> {
190190
// The VM itself has no filesystem access.
191191
let path = if path.is_empty() { "???" } else { path };
192192
match std::fs::read_to_string(path) {
193-
Ok(source) => vm.run_string(scope, &source, path.to_owned()).map(drop),
193+
Ok(source) => vm.run_string(scope, &source, path).map(drop),
194194
Err(err) => Err(vm.new_os_error(err.to_string())),
195195
}
196196
}

0 commit comments

Comments
 (0)