Menu

#17 Flashplayer crashes on empty file

gplflash2
closed-fixed
nobody
None
5
2005-08-28
2005-07-04
No

If an empty file is fed to flashplayer, a segmentation
fault occurs. This appears to be a logic error in
Swf_decoder::readStream. See also backtrace below.

Steps to reproduce:
1. Create an empty file: touch empty.swf
2. flashplayer empty.swf - crashes

Backtrace:

Starting program:
/home/robert/devel/gplflash2/src/gplflash2/player/flashplayer
empty.swf
[Thread debugging using libthread_db enabled]
[New Thread 46912547698624 (LWP 526)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 46912547698624 (LWP 526)]
0x000000000040b26f in Swf_decoder::getBitFieldUnsigned
(this=0x685f70,
length=5) at swf_decoder.cc:146
146 res = (res << 1) |
((decodeBuffer[loc]>>pos)&1);
(gdb) bt
#0 0x000000000040b26f in
Swf_decoder::getBitFieldUnsigned (this=0x685f70,
length=5) at swf_decoder.cc:146
#1 0x000000000040af27 in Swf_decoder::readStream
(this=0x685f70,
data=0x6862a0 "", size=0) at swf_decoder.cc:85
#2 0x000000000040994d in openDecodeStream (
fileName=0x7fffffffe41a "empty.swf",
decoder=0x685f70) at flashplayer.cc:56
#3 0x000000000040a47e in main (argc=2,
argv=0x7fffffffe0f8)
at flashplayer.cc:257

Discussion

  • Tomas Groth

    Tomas Groth - 2005-08-28
    • status: open --> closed
     
  • Tomas Groth

    Tomas Groth - 2005-08-28
    • status: closed --> closed-fixed
     

Log in to post a comment.