aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sci-astronomy/astrometry/files/0.38-strict-aliasing.patch')
-rw-r--r--sci-astronomy/astrometry/files/0.38-strict-aliasing.patch30
1 files changed, 30 insertions, 0 deletions
diff --git a/sci-astronomy/astrometry/files/0.38-strict-aliasing.patch b/sci-astronomy/astrometry/files/0.38-strict-aliasing.patch
new file mode 100644
index 000000000..f9d09a1cf
--- /dev/null
+++ b/sci-astronomy/astrometry/files/0.38-strict-aliasing.patch
@@ -0,0 +1,30 @@
+diff -Nur astrometry.net-0.38.orig/qfits-an/src/qfits_image.c astrometry.net-0.38/qfits-an/src/qfits_image.c
+--- astrometry.net-0.38.orig/qfits-an/src/qfits_image.c 2009-11-30 15:13:05.000000000 +0000
++++ astrometry.net-0.38/qfits-an/src/qfits_image.c 2012-05-09 22:51:13.000000000 +0100
+@@ -1100,7 +1100,7 @@
+ #ifndef WORDS_BIGENDIAN
+ qfits_swap_bytes(XLpix, 8);
+ #endif
+- dpix = *((double*)XLpix);
++ dpix = (double)(*XLpix);
+ *p_dest ++ = (float)(bscale * dpix + bzero);
+ }
+ break;
+@@ -1200,7 +1200,7 @@
+ #ifndef WORDS_BIGENDIAN
+ qfits_swap_bytes(XLpix, 8);
+ #endif
+- dpix = *((double*)XLpix);
++ dpix = (double)(*XLpix);
+ *p_dest ++ = (int)(bscale * dpix + bzero);
+ }
+ break;
+@@ -1301,7 +1301,7 @@
+ #ifndef WORDS_BIGENDIAN
+ qfits_swap_bytes(XLpix, 8);
+ #endif
+- dpix = *((double*)XLpix);
++ dpix = (double)(*XLpix);
+ *p_dest ++ = (double)(bscale * dpix + bzero);
+ }
+ break;