|
Lines 812-818
gdk_pixbuf__jpeg_image_load_increment (gpointer data,
Link Here
|
| 812 |
struct jpeg_decompress_struct *cinfo; |
812 |
struct jpeg_decompress_struct *cinfo; |
| 813 |
my_src_ptr src; |
813 |
my_src_ptr src; |
| 814 |
guint num_left, num_copy; |
814 |
guint num_left, num_copy; |
| 815 |
guint last_bytes_left; |
815 |
guint last_num_left, last_bytes_left; |
| 816 |
guint spinguard; |
816 |
guint spinguard; |
| 817 |
gboolean first; |
817 |
gboolean first; |
| 818 |
const guchar *bufhd; |
818 |
const guchar *bufhd; |
|
Lines 853-858
gdk_pixbuf__jpeg_image_load_increment (gpointer data,
Link Here
|
| 853 |
if (num_left == 0) |
853 |
if (num_left == 0) |
| 854 |
return TRUE; |
854 |
return TRUE; |
| 855 |
|
855 |
|
|
|
856 |
last_num_left = num_left; |
| 856 |
last_bytes_left = 0; |
857 |
last_bytes_left = 0; |
| 857 |
spinguard = 0; |
858 |
spinguard = 0; |
| 858 |
first = TRUE; |
859 |
first = TRUE; |
|
Lines 880-889
gdk_pixbuf__jpeg_image_load_increment (gpointer data,
Link Here
|
| 880 |
if (first) { |
881 |
if (first) { |
| 881 |
last_bytes_left = src->pub.bytes_in_buffer; |
882 |
last_bytes_left = src->pub.bytes_in_buffer; |
| 882 |
first = FALSE; |
883 |
first = FALSE; |
| 883 |
} else if (src->pub.bytes_in_buffer == last_bytes_left) |
884 |
} else if (src->pub.bytes_in_buffer == last_bytes_left |
|
|
885 |
&& num_left == last_num_left) { |
| 884 |
spinguard++; |
886 |
spinguard++; |
| 885 |
else |
887 |
} else { |
| 886 |
last_bytes_left = src->pub.bytes_in_buffer; |
888 |
last_bytes_left = src->pub.bytes_in_buffer; |
|
|
889 |
last_num_left = num_left; |
| 890 |
} |
| 887 |
|
891 |
|
| 888 |
/* should not go through twice and not pull bytes out of buf */ |
892 |
/* should not go through twice and not pull bytes out of buf */ |
| 889 |
if (spinguard > 2) |
893 |
if (spinguard > 2) |