Okay, how do I do this? Also, if you look at the code, I build a 32-bit unsigned integer from the bytes I read. And the 32-bit pattern I am looking for can start on _any_ byte boundary in the file. It would be nice if I could somehow just scan for that pattern explicitly, without having to build a 32-bit integer first. If I could tell python "scan this file for the bytes 0, 0, 1, 0 in succession. How many 0, 0, 1, 0 did you find?"
/David -- http://mail.python.org/mailman/listinfo/python-list