Skip to content

Commit 54a5d1e

Browse files
committed
invalid buffer size in ang2pix(..., lonlat=True)
1 parent cf063c0 commit 54a5d1e

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

python/healpix/__init__.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,8 @@ def ang2pix(nside, theta, phi, nest=False, lonlat=False):
7272
['buffered', 'external_loop', 'zerosize_ok'],
7373
[['readonly']]*2 + [['writeonly', 'allocate']]*1,
7474
[None, None, int]) as it:
75-
theta, phi = None, None
7675
for lon, lat, ipix in it:
77-
theta, phi = thetaphi_from_lonlat(lon, lat, theta, phi)
76+
theta, phi = thetaphi_from_lonlat(lon, lat)
7877
if nest:
7978
_chp.ang2nest(nside, theta, phi, ipix)
8079
else:

0 commit comments

Comments
 (0)