allow more operations to work on detached streams (closes #23093)

Patch by Martin Panter.