projects
/
libam7xxx.git
/ commitdiff
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4415084
)
am7xxx: use debug() instead of fatal() in add_new_device()
author
Antonio Ospite <ao2@ao2.it>
Wed, 10 Jun 2015 11:16:02 +0000
(13:16 +0200)
committer
Antonio Ospite <ao2@ao2.it>
Wed, 10 Jun 2015 13:17:50 +0000
(15:17 +0200)
We are guaranteed that ctx is non-null by a previous check.
src/am7xxx.c
patch
|
blob
|
history
diff --git
a/src/am7xxx.c
b/src/am7xxx.c
index
c18e202
..
dd69fc5
100644
(file)
--- a/
src/am7xxx.c
+++ b/
src/am7xxx.c
@@
-664,7
+664,7
@@
static am7xxx_device *add_new_device(am7xxx_context *ctx,
new_device = malloc(sizeof(*new_device));
if (new_device == NULL) {
-
fatal(
"cannot allocate a new device (%s)\n", strerror(errno));
+
debug(ctx,
"cannot allocate a new device (%s)\n", strerror(errno));
return NULL;
}
memset(new_device, 0, sizeof(*new_device));