[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnuastro-commits] master f99229c: Warp working when type isn't specifie
From: |
Mohammad Akhlaghi |
Subject: |
[gnuastro-commits] master f99229c: Warp working when type isn't specified |
Date: |
Sat, 11 Aug 2018 12:12:55 -0400 (EDT) |
branch: master
commit f99229c1de9192b7b2760db88de9dc62b54f999a
Author: Mohammad Akhlaghi <address@hidden>
Commit: Mohammad Akhlaghi <address@hidden>
Warp working when type isn't specified
When the type of the output isn't specified in Warp, it will crash. To fix
the problem, a check has been added to only try changing the internal
`float64' type to another type when `p->cp.type!=0'.
This fixes bug #54493.
---
NEWS | 1 +
bin/warp/warp.c | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/NEWS b/NEWS
index b3cdc2d..78e8e16 100644
--- a/NEWS
+++ b/NEWS
@@ -32,6 +32,7 @@ GNU Astronomy Utilities NEWS -*-
outline -*-
-- gal_fits_key_write_filename: write at the top or end of the input list.
** Bugs fixed
+ bug #54493: Warp crashes when type isn't set.
diff --git a/bin/warp/warp.c b/bin/warp/warp.c
index 14e15f8..fe89313 100644
--- a/bin/warp/warp.c
+++ b/bin/warp/warp.c
@@ -470,7 +470,7 @@ correct_wcs_save_output(struct warpparams *p)
}
/* Save the output into the proper type and write it. */
- if(p->cp.type!=p->output->type)
+ if(p->cp.type && p->cp.type!=p->output->type)
p->output=gal_data_copy_to_new_type_free(p->output, p->cp.type);
gal_fits_img_write(p->output, p->cp.output, headers, PROGRAM_NAME);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [gnuastro-commits] master f99229c: Warp working when type isn't specified,
Mohammad Akhlaghi <=