Thread (15 messages) 15 messages, 4 authors, 2013-05-21

Re: [PATCH v2] Bluetooth: hidp: using strlcpy instead of strncpy, also beautify code.

From: Chen Gang <hidden>
Date: 2013-05-09 08:48:38
Also in: linux-bluetooth

On 05/09/2013 04:42 PM, Jiri Kosina wrote:
On Wed, 8 May 2013, Chen Gang wrote:
quoted
quoted
For NUL terminated string, need always let it ended by zero.

Since have already called memcpy() to initialize 'ci', so need not
redundent initializations.

Better use ''if(session->hid) {} else if(session->input) {}'' instead
of ''if(session->hid) {}; if(session->input) {};''

Signed-off-by: Chen Gang <redacted>
Makes sense.

Acked-by: Jiri Kosina <redacted>

Gustavo, going to take this, please?

-- Jiri Kosina SUSE Labs
Thanks, and also help to fix the spelling: redundent -> redundant.
(if need let me send patch v3, please reply to tell me, thanks)


-- 
Chen Gang

Asianux Corporation
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help