daemon/attach: avoid mem alloc for interface

Docker-DCO-1.1-Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com> (github: unclejack)
Merge pull request #8169 from unclejack/avoid_attach_alloc

daemon/attach: avoid mem alloc for interface