Page MenuHomePhabricator

Fix an issue where resolveKill() emits a warning if the future was never started
ClosedPublic

Authored by epriestley on Feb 14 2017, 3:17 PM.
Tags
None
Referenced Files
F13060687: D17354.diff
Fri, Apr 19, 6:14 PM
Unknown Object (File)
Mon, Apr 8, 12:20 AM
Unknown Object (File)
Sun, Apr 7, 5:35 AM
Unknown Object (File)
Sun, Apr 7, 4:40 AM
Unknown Object (File)
Thu, Apr 4, 9:36 PM
Unknown Object (File)
Thu, Apr 4, 5:32 PM
Unknown Object (File)
Mon, Apr 1, 3:11 AM
Unknown Object (File)
Mar 10 2024, 8:18 AM
Subscribers
None

Details

Summary

Ref T2794. This is a minor warning I hit while exploring Phage stuff. In Phage, we can resolveKill() a future that we never called start() on, which tries to proc_terminate() a process which never spawned. This emits a warning.

Instead, check that $this->proc exists before signaling it.

Test Plan

Added a unit test.

Diff Detail

Repository
rPHU libphutil
Lint
Lint Not Applicable
Unit
Tests Not Applicable