[pygobject] pygi_arg_cache_alloc() never returns NULL
- From: Christoph Reiter <creiter src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pygobject] pygi_arg_cache_alloc() never returns NULL
- Date: Thu, 29 Mar 2018 20:07:10 +0000 (UTC)
commit ed8538d8b7de45050d931edd036853944ff04d47
Author: Christoph Reiter <reiter christoph gmail com>
Date: Thu Mar 29 22:02:36 2018 +0200
pygi_arg_cache_alloc() never returns NULL
gi/pygi-basictype.c | 2 --
gi/pygi-error.c | 4 +---
2 files changed, 1 insertion(+), 5 deletions(-)
---
diff --git a/gi/pygi-basictype.c b/gi/pygi-basictype.c
index 05080306..27966bfe 100644
--- a/gi/pygi-basictype.c
+++ b/gi/pygi-basictype.c
@@ -1062,8 +1062,6 @@ pygi_arg_basic_type_new_from_info (GITypeInfo *type_info,
{
gboolean res = FALSE;
PyGIArgCache *arg_cache = pygi_arg_cache_alloc ();
- if (arg_cache == NULL)
- return NULL;
res = arg_basic_type_setup_from_info (arg_cache,
type_info,
diff --git a/gi/pygi-error.c b/gi/pygi-error.c
index 4feefc4b..18c488a0 100644
--- a/gi/pygi-error.c
+++ b/gi/pygi-error.c
@@ -328,11 +328,9 @@ pygi_arg_gerror_new_from_info (GITypeInfo *type_info,
PyGIDirection direction)
{
gboolean res = FALSE;
- PyGIArgCache *arg_cache = NULL;
+ PyGIArgCache *arg_cache;
arg_cache = pygi_arg_cache_alloc ();
- if (arg_cache == NULL)
- return NULL;
res = pygi_arg_gerror_setup_from_info (arg_cache,
type_info,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]