ebin123456 / py-amqplib

Automatically exported from code.google.com/p/py-amqplib
GNU Lesser General Public License v2.1
0 stars 0 forks source link

Defensive try catch #6

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
In abstract channel, lines 94 - 97 are hiding bugs. I'm tracking down a
case where the channel's connection is None, which is an internal bug
(either in the library code or mine) but it's being ignored by that try
catch block.

Original issue reported on code.google.com by g%rre.tt@gtempaccount.com on 17 Sep 2009 at 6:27

GoogleCodeExporter commented 9 years ago
This part?

            try:
                content.body = content.body.decode(content.content_encoding)
            except Exception:
                pass

All that protects is a single string decoding operation, so that if there was a
problem, the content.body, whatever it is, remains unchanged.  Not sure what 
that
would have to do with connections at all.

Original comment by barry.pe...@gmail.com on 17 Sep 2009 at 8:23

GoogleCodeExporter commented 9 years ago
My apologies -- I got this report completely wrong (I think I got the trace back
mixed up within another one). Sorry about that.

Original comment by g%rre.tt@gtempaccount.com on 18 Sep 2009 at 1:29

GoogleCodeExporter commented 9 years ago
OK, I'll mark this closed then.

Original comment by barry.pe...@gmail.com on 18 Sep 2009 at 2:46