[valgrind] conditional depends on unitialized data in png writer

RESOLVED INVALID

Status

Core Graveyard
Image: Painting
RESOLVED INVALID
11 years ago
8 years ago

People

(Reporter: Robert Sayre, Unassigned)

Tracking

({valgrind})

Firefox Tracking Flags

(Not tracked)

Details

(URL)

(Reporter)

Description

11 years ago
See URL.

==29183== Conditional jump or move depends on uninitialised value(s)
==29183==    at 0x49B6D12: longest_match (deflate.c:1143)
==29183==    by 0x49B7D92: deflate_slow (deflate.c:1595)
==29183==    by 0x49B75F1: MOZ_Z_deflate (deflate.c:790)
==29183==    by 0x7E8F77B: MOZ_PNG_write_finish_row (pngwutil.c:1996)
==29183==    by 0x7E8F8F4: MOZ_PNG_write_filtered_row (pngwutil.c:2873)
==29183==    by 0x7E8F93B: MOZ_PNG_write_find_filter (pngwutil.c:2806)
==29183==    by 0x7E8CB75: MOZ_PNG_write_row (pngwrite.c:918)
==29183==    by 0x7E72C03: nsPNGEncoder::AddImageFrame(unsigned char const*, unsigned, unsigned, unsigned, unsigned, unsigned, nsAString_internal const&) (nsPNGEncoder.cpp:267)
==29183==    by 0x7E722B2: nsPNGEncoder::InitFromData(unsigned char const*, unsigned, unsigned, unsigned, unsigned, unsigned, nsAString_internal const&) (nsPNGEncoder.cpp:99)
==29183==    by 0x794BA31: nsCanvasRenderingContext2D::GetInputStream(char const*, unsigned short const*, nsIInputStream**) (nsCanvasRenderingContext2D.cpp:775)
==29183==    by 0x79926E5: nsHTMLCanvasElement::ToDataURLImpl(nsAString_internal const&, nsAString_internal const&, nsAString_internal&) (nsHTMLCanvasElement.cpp:380)
==29183==    by 0x7992C84: nsHTMLCanvasElement::ToDataURL(nsAString_internal&) (nsHTMLCanvasElement.cpp:317)

Comment 1

11 years ago
http://www.zlib.net/zlib_faq.html#faq36 sounds relevant here, and http://archives.devshed.com/forums/compression-130/zlib-1-2-1-valgrind-warnings-314459.html says longest_match is intentionally using uninitialised values and will cause this warning when there is no actual problem.
(Reporter)

Comment 2

11 years ago
nice, ok. INVALID.
Status: NEW → RESOLVED
Last Resolved: 11 years ago
Resolution: --- → INVALID
Keywords: valgrind

Updated

9 years ago
Component: Image: Painting → Image: Painting
Product: Core → Core Graveyard

Updated

8 years ago
Duplicate of this bug: 581181
This innocuous bug will be fixed by checkin of libz-1.2.5, bug #573137.
Depends on: 573137
You need to log in before you can comment on or make changes to this bug.