C-API: A beginner's problem

Heikki Salo hosalo at _NO_SPAM_gmail.com
Sun Mar 19 16:04:59 CET 2006


Fabian Steiner wrote:
> What did I do wrong? As I am quite new to C, I probably made many 
> mistakes, so please feel free to correct me.

The following line:

 >     for (i = 0; i <= seqlen; i++) {

Should be "for (i = 0; i < seqlen; i++) {". Otherwise the last 
assignment will be out of bounds and probably corrupts heap.



More information about the Python-list mailing list