From: Niklas Haas <ffmpeg@haasn.xyz> To: ffmpeg-devel@ffmpeg.org Subject: Re: [FFmpeg-devel] [PATCH v7 1/2] avcodec/pngenc: support writing iCCP chunks Date: Tue, 5 Apr 2022 12:59:32 +0200 Message-ID: <20220405125932.GB55885@haasn.xyz> (raw) In-Reply-To: <AS1PR01MB9564F61430F777C9A108E9778FE09@AS1PR01MB9564.eurprd01.prod.exchangelabs.com> On Fri, 01 Apr 2022 15:31:16 +0200 Andreas Rheinhardt <andreas.rheinhardt@outlook.com> wrote: > Passing the PNGEncContext would be more natural. Changed. > Since db57a5370bd37105d389a45b04bf4970802407ec the callers' > max_packet_size are not size_t any more, but always 64bit (so that > there's no truncation in case size_t is 32bit). Changed. > ULONG_MAX is the maximum of unsigned long, yet deflateBound uses uLong. > The latter is a currently typedef for unsigned long, but do we want to > rely on that? The ordinary way to check for whethe a value can be > represented in a type is by "if (sd->size != (uLong)sd->size)" Changed. I didn't know about this trick, thanks. > AV_LOG_WARNING makes no sense given that you error out afterwards. > (And anyway: Is a log-message really needed for something that will > never happen in reality?) I think you're right. For JPEG it makes sense to keep around an error printout, because the JPEG profile limit is quite small in comparison (16 MB - the largest ICC profiles I have encountered in the wild are on the order of megabytes as well). But PNG supports up to 4 GB ICC profiles, which strains all conceivable credibility. Somebody would have to be deliberately trying to hit this limitation. Removed both error printouts (including the one about zlib misbehaving, equally unlikely). _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
prev parent reply other threads:[~2022-04-05 10:59 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-03-28 15:26 Niklas Haas 2022-03-28 15:26 ` [FFmpeg-devel] [PATCH v7 2/2] avcodec/mjpegenc: support writing ICC profiles Niklas Haas 2022-04-01 13:31 ` [FFmpeg-devel] [PATCH v7 1/2] avcodec/pngenc: support writing iCCP chunks Andreas Rheinhardt 2022-04-05 10:59 ` Niklas Haas [this message]
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20220405125932.GB55885@haasn.xyz \ --to=ffmpeg@haasn.xyz \ --cc=ffmpeg-devel@ffmpeg.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git