Skip to content

Commit 992078a

Browse files
committed
Merge pull request #6 from jossgray/master
Return error if frame is chunked and no valid callback was given.
2 parents ee7ceb4 + 44089ef commit 992078a

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Diff for: source/hap.c

+5
Original file line numberDiff line numberDiff line change
@@ -418,6 +418,11 @@ unsigned int HapDecode(const void *inputBuffer, unsigned long inputBufferBytes,
418418
compressor = hap_top_4_bits(sectionType);
419419
textureFormat = hap_bottom_4_bits(sectionType);
420420

421+
if (compressor == kHapCompressorComplex && callback == NULL)
422+
{
423+
return HapResult_Bad_Arguments;
424+
}
425+
421426
/*
422427
Pass the texture format out
423428
*/

0 commit comments

Comments
 (0)