{"action":"closed","issue":{"url":"https://api.github.com/repos/rust-lang/cargo/issues/2525","repository_url":"https://api.github.com/repos/rust-lang/cargo","labels_url":"https://api.github.com/repos/rust-lang/cargo/issues/2525/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang/cargo/issues/2525/comments","events_url":"https://api.github.com/repos/rust-lang/cargo/issues/2525/events","html_url":"https://github.com/rust-lang/cargo/issues/2525","id":143846056,"number":2525,"title":"`cargo run` should wait for child termination in case of SIGINT/SIGTERM","user":{"login":"troplin","id":13793075,"avatar_url":"https://avatars.githubusercontent.com/u/13793075?v=3","gravatar_id":"","url":"https://api.github.com/users/troplin","html_url":"https://github.com/troplin","followers_url":"https://api.github.com/users/troplin/followers","following_url":"https://api.github.com/users/troplin/following{/other_user}","gists_url":"https://api.github.com/users/troplin/gists{/gist_id}","starred_url":"https://api.github.com/users/troplin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/troplin/subscriptions","organizations_url":"https://api.github.com/users/troplin/orgs","repos_url":"https://api.github.com/users/troplin/repos","events_url":"https://api.github.com/users/troplin/events{/privacy}","received_events_url":"https://api.github.com/users/troplin/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-03-27T20:33:14Z","updated_at":"2016-03-28T03:53:10Z","closed_at":"2016-03-28T03:53:10Z","body":"I'm not sure if this is the same issue as #2343, at least it is related\r\n\r\nIf the child application handles signals, `cargo run` exits before the child process. This leads to strange effects like the output of the child process appearing on/after the prompt:\r\n```\r\nroot@29c089056c4d:/shares/Development/test# RUST_LOG=test=debug cargo run --release\r\n     Running `target/release/test`\r\nINFO:test: test v0.1.0 started\r\n^C\r\nroot@29c089056c4d:/shares/Development/test# INFO:test: Recieved signal [Int], shutting down\r\nINFO:test: test v0.1.0 stopped\r\n```\r\nIf I run the `test` application directly it looks like:\r\n```\r\nroot@29c089056c4d:/shares/Development/test# RUST_LOG=test=debug target/release/test \r\nINFO:test: test v0.1.0 started\r\n^CINFO:test: Recieved signal [Int], shutting down\r\nINFO:test: test v0.1.0 stopped\r\nroot@29c089056c4d:/shares/Development/test# \r\n```\r\nI think `cargo run` should handle the signals and wait for the exit of the child process."}}