From c95d8e05ca80064f19b5b78b2e705c1afe0fec5c Mon Sep 17 00:00:00 2001 From: Peter Hutterer Date: Wed, 2 Mar 2016 14:05:43 +1000 Subject: [PATCH] lur: Add a note that we're not doing OOM Mostly inherited from our zalloc() implementation. But really, if you have no memory left, should you be trying to talk to receivers? Signed-off-by: Peter Hutterer --- src/liblur.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/liblur.h b/src/liblur.h index cb97bc1a..26395ce1 100644 --- a/src/liblur.h +++ b/src/liblur.h @@ -111,6 +111,9 @@ lur_is_receiver(uint16_t vid, uint16_t pid); * * @return 0 on success or a negative errno on error * @retval -EINVAL The fd does not point to a lur receiver + * + * @note liblur does not have OOM handling. If an allocation fails, liblur + * will simply abort() */ int lur_receiver_new_from_hidraw(int fd, void *userdata, struct lur_receiver **lur);