[Python-checkins] gh-111178: fix UBSan failures in `Modules/zlibmodule.c` (GH-128252)