#495 closed defect (fixed)

zfec crashes and incorrect precondition values

Reported by: greg Owned by: zooko
Priority: minor Milestone: undecided
Component: code Version: unknown
Keywords: Cc:
Launchpad Bug:

Description

in zfec 1.4.0, these things cause a crash:

python -c "import zfec; zfec.Encoder()"
Segmentation fault
python -c "import zfec; zfec.Decoder()"
Segmentation fault

Additionally (if it didn't crash right away) the preconition check has an incorrect value:

python -c "import zfec; zfec.Encoder(1, 257)"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
_fec.Error: Precondition violation: second argument is required to be less than or equal to 256, but it was 0

Notice "0" instead of "257".

This patch fixes both of these issues.

Attachments (1)

crash_precond.diff (2.7 KB) - added by greg at 2008-07-25T16:32:18Z.
fix crash and precondition exception

Download all attachments as: .zip

Change History (2)

Changed at 2008-07-25T16:32:18Z by greg

fix crash and precondition exception

comment:1 Changed at 2009-07-11T11:31:12Z by warner

  • Component changed from unknown to code
  • Resolution set to fixed
  • Status changed from new to closed

This appears to be fixed in zfec-1.4.5

Note: See TracTickets for help on using tickets.