Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gdk_pixbuf throwing inaccurate exceptions #118

Closed
CromFr opened this issue Jun 27, 2015 · 2 comments

Comments

Projects
None yet
2 participants
@CromFr
Copy link

commented Jun 27, 2015

https://github.com/gtkd-developers/GtkD/blob/master/src/gdkpixbuf/Pixbuf.d#L344
Should be more like:

public this(string filename)
{
    GError* err = null;
    auto p = gdk_pixbuf_new_from_file(Str.toStringz(filename), &err);
    if(p is null)
    {
        if (err !is null)
        {
            throw new GException( new ErrorG(err) );
        }
        throw new ConstructionException("null returned by new_from_file");
    }
    this(cast(GdkPixbuf*) p, true);
}

The same issue happens in other parts of the same file, maybe also in other files.

@MikeWey MikeWey added the Bug label Jun 27, 2015

@MikeWey MikeWey self-assigned this Jun 27, 2015

@MikeWey MikeWey closed this in 0490ce5 Jun 27, 2015

@MikeWey

This comment has been minimized.

Copy link
Member

commented Jun 27, 2015

There were indeed more places where this heapend.

@CromFr

This comment has been minimized.

Copy link
Author

commented Jun 27, 2015

Thanks for fixing this issue so quickly :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.