OBEX_ResponseToString() documentation says that it returns a static
string or NULL on error. This is not quite correct as the code does
never return NULL, and moreover it will be easier to use if that is
part of the API. Make it so.
---
 lib/obex.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/lib/obex.c b/lib/obex.c
index 29723ec..4704e5d 100644
--- a/lib/obex.c
+++ b/lib/obex.c
@@ -841,9 +841,11 @@ int CALLAPI OBEX_ObjectGetCommand(obex_t *self, 
obex_object_t *object)
 /**
        Return a human understandable string from a response-code.
        \param rsp Response code.
-       \return static response code string, NULL on error
+       \return static response code string
 
-       The returned char must not be freed. Returns NULL on error.
+       The returned string must not be freed.
+       If the response code is unknown, the string "Unknown response" will
+       be returned.
  */
 LIB_SYMBOL
 char * CALLAPI OBEX_ResponseToString(int rsp)
-- 
1.7.0.5


------------------------------------------------------------------------------
Learn how Oracle Real Application Clusters (RAC) One Node allows customers
to consolidate database storage, standardize their database environment, and, 
should the need arise, upgrade to a full multi-node Oracle RAC database 
without downtime or disruption
http://p.sf.net/sfu/oracle-sfdevnl
_______________________________________________
Openobex-users mailing list
Openobex-users@lists.sourceforge.net
http://lists.sourceforge.net/lists/listinfo/openobex-users

Reply via email to