Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 90f0e07

Browse files
committed
fix glaring bug in get_magic
1 parent 42a5124 commit 90f0e07

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Python/import.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -651,8 +651,8 @@ imp_get_magic(self, args)
651651
return NULL;
652652
buf[0] = (MAGIC >> 0) & 0xff;
653653
buf[1] = (MAGIC >> 8) & 0xff;
654-
buf[3] = (MAGIC >> 16) & 0xff;
655-
buf[4] = (MAGIC >> 24) & 0xff;
654+
buf[2] = (MAGIC >> 16) & 0xff;
655+
buf[3] = (MAGIC >> 24) & 0xff;
656656

657657
return newsizedstringobject(buf, 4);
658658
}

0 commit comments

Comments
 (0)