Index: wp-includes/media.php
===================================================================
--- wp-includes/media.php	(revision 19034)
+++ wp-includes/media.php	(working copy)
@@ -644,6 +644,8 @@ function wp_get_attachment_image($attachment_id, $size = 'thumbnail', $icon = fa
 	$image = wp_get_attachment_image_src($attachment_id, $size, $icon);
 	if ( $image ) {
 		list($src, $width, $height) = $image;
+		if ( is_ssl() )
+			$src = str_replace( 'http://', 'https://', $src );
 		$hwstring = image_hwstring($width, $height);
 		if ( is_array($size) )
 			$size = join('x', $size);
