Fix memory leak of the cgimage to silence the analyzer

I'm not completely sure that the private API UIGetScreenImage() really
follows the Cocoa naming conventions, so it might be that that image
is still leaked. However, that doesn't really matter since this is
only ran in screenshot mode, but it helps to not have the analyzer
warn if you usually have no warnings in your code.