Replace an OS X-only temporary file hack.

Replace the temporary file hack currently used to change Bitcoin-Qt's dock icon (OS X) with a buffer-based solution.