Skip to content

Commit a8d57db

Browse files
committed
fix a segv with libvips 8.16
1 parent 437905f commit a8d57db

File tree

4 files changed

+7
-2
lines changed

4 files changed

+7
-2
lines changed

TODO

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
- fix scRGB with alpha
12

23
- "reset" in display bar resets the position of scale/offset widgets, but does
34
not reset the menu items (eg. tick on falsecolour)

src/main-batch.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -316,6 +316,9 @@ main_print_ws(Workspace *ws, gboolean *found)
316316
int
317317
main(int argc, char **argv)
318318
{
319+
if (VIPS_INIT(argv[0]))
320+
vips_error_exit("unable to start libvips");
321+
319322
main_option_batch = TRUE;
320323
main_option_no_load_menus = TRUE;
321324

src/main-gui.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@ static GOptionEntry main_gui_options[] = {
3939
int
4040
main(int argc, char **argv)
4141
{
42+
if (VIPS_INIT(argv[0]))
43+
vips_error_exit("unable to start libvips");
44+
4245
/* First time we've been run? Show a welcome message. We must do this
4346
* before main_startup().
4447
*/

src/main.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,8 +169,6 @@ void
169169
main_startup(int argc, char **argv)
170170
{
171171
main_argv0 = argv[0];
172-
if (VIPS_INIT(argv[0]))
173-
vips_error_exit("unable to start libvips");
174172

175173
#ifdef DEBUG
176174
vips_leak_set(TRUE);

0 commit comments

Comments
 (0)