Arduino Yun - How to close http client connections?

What you're doing is fine.

HttpClient inherits from Process, and is implemented by calling curl on the Linux side. The destructor for Process calls close(), so this will be called when your client instance is destroyed before loop() returns.