#2537 reduce memory usage of downloaded images