Commits

Anonymous committed 6342ce4

Fix accidentally reversed NULL test in load_mark(). Suggested by
Tamito Kajiyama. (This caused a bug only on platforms where malloc(0)
returns NULL.)

  • Participants
  • Parent commits 885be60
  • Branches legacy-trunk

Comments (0)

Files changed (1)

File Modules/cPickle.c

     if ((self->num_marks + 1) >= self->marks_size) {
         s=self->marks_size+20;
         if (s <= self->num_marks) s=self->num_marks + 1;
-        if (self->marks)
+        if (self->marks == NULL)
             self->marks=(int *)malloc(s * sizeof(int));
         else
             self->marks=(int *)realloc(self->marks, s * sizeof(int));