MB-5307 Explicitly close file when handling memcached logs.

Change-Id: I344930b8a2b8177d28bcb9f3e8df80baccdbcae5
Reviewed-on: http://review.couchbase.org/24071
Tested-by: Aliaksey Artamonau <aliaksiej.artamonau@gmail.com>
Reviewed-by: Aliaksey Kandratsenka <alkondratenko@gmail.com>