Check available memory for image resizing with GD on Windows (#1489937)