Skip to content

Commit dd21f55

Browse files
author
nnorwitz
committed
Fix SF #639945, 64-bit bug on AIX
I can't test this on the snake farm (no aix box is working). This change works for the submitter seems correct. Can anybody test this on 32- and 64- bit AIX? git-svn-id: http://svn.python.org/projects/python/trunk@30389 6015fed2-1504-0410-9fe1-9d1591cc4771
1 parent af67397 commit dd21f55

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

Python/dynload_aix.c

+2-3
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,7 @@ aix_getoldmodules(void **modlistptr)
7777
-- "libpython[version].a" in case it's a shared lib).
7878
*/
7979
offset = (unsigned int)ldiptr->ldinfo_next;
80-
ldiptr = (struct ld_info *)((unsigned int)
81-
ldiptr + offset);
80+
ldiptr = (struct ld_info *)((char*)ldiptr + offset);
8281
continue;
8382
}
8483
if ((modptr = (ModulePtr)malloc(sizeof(Module))) == NULL) {
@@ -98,7 +97,7 @@ aix_getoldmodules(void **modlistptr)
9897
prevmodptr->next = modptr;
9998
prevmodptr = modptr;
10099
offset = (unsigned int)ldiptr->ldinfo_next;
101-
ldiptr = (struct ld_info *)((unsigned int)ldiptr + offset);
100+
ldiptr = (struct ld_info *)((char*)ldiptr + offset);
102101
} while (offset);
103102
free(ldibuf);
104103
return 0;

0 commit comments

Comments
 (0)