| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
This also fixes the bug where we were always testing against the fake
strlcpy we provide for glibc/Windows rather than the Android one.
This also removes some unnecessary library dependencies.
This also builds all the cutils tests for the host (static and dynamic).
Change-Id: Icd129d5b025c0ca801be5acf31a54ecd88608df9
|
|\
| |
| |
| |
| | |
* commit 'a0a461d3b7d85484c10db64f078427a5be3da189':
libcutils: turn on -Werror
|
| |
| |
| |
| |
| |
| | |
- Deal with some -Wunused / -Wunused-variable issues
Change-Id: I28c23fb213382a392ec30935749fb359e072d664
|
|\ \
| |/
| |
| |
| |
| |
| | |
corrupt str_parms"
* commit '4fe186159386a75ce17ca0b7ba6ace4294187cb2':
Handle errno properly to avoid corrupt str_parms
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
A normal sequence of calls is as follows:
str_parms_create_str, str_parms_add_str, str_parms_destroy.
In some cases the destroy caused double free.
str_parms_add_str will clone the input and send it to hashmapPut
for storage. If hashmapPut did not store the strings it will raise
errno = ENOMEM and leave caller with ownership of the strings.
In any of these cases it will be safe to destroy the str_parms.
But what if it wasn't hashmapPut that said NOMEM? What if there
was a stale NOMEM already before a successful hashmapPut?
In that case the strings will be successfully added to the list
(if new), but when str_parms_add_str sees the NOMEM it will free
them anyway, leaving dangling pointers in the str_parms!!
It is the responsibility of the caller to clear errno before any
interesting call. This patch makes sure that str_parms_add_str
reacts only on errno emmitted from hashmapPut.
Change-Id: If87e4bcc482f09e1c66133d33517b152ebdac65f
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
str_parms_get_float did not return the output into
*val. Only output if returning with no error. Audit
shows no internal users of this library function
(cherry picked from commit 8e71ddeac00d0733c7fcc2965d69f07aa5c5d0a3)
Change-Id: I14a3f08a098072a159dd93f85ead36b3f445816f
|
| |
| |
| |
| |
| |
| | |
(cherry picked from commit ba02cd1e9bccee9b112ccbee06bc204381b5a215)
Change-Id: Ie427d481298af8d911bb2b157ebba30954335354
|
| |
| |
| | |
Change-Id: I1af5c260a1a820b65f0850ea9adb38b01fcb183c
|
| |
| |
| |
| |
| |
| |
| |
| | |
str_parms_get_float did not return the output into
*val. Only output if returning with no error. Audit
shows no internal users of this library function
Change-Id: I14a3f08a098072a159dd93f85ead36b3f445816f
|
|/
|
|
| |
Change-Id: Ie427d481298af8d911bb2b157ebba30954335354
|
|
|
|
|
|
|
|
|
|
| |
When removing one entry, we can't just remove it from the map since
key will not be freed. So, instead, search through the map for the key
and free it once it is found.
Change-Id: Id745c166a4acc5ea25f6d6cdbfe4f8fbc21cbbb3
Reported-by: Xin Qian <xqian@marvell.com>
Signed-off-by: Dima Zavin <dima@android.com>
|
|
|
|
|
|
| |
Change-Id: I9f31da62f10f78ed11693a7c04e2be29b0790c93
Reported-by: Xin Qian <xqian@marvell.com>
Signed-off-by: Dima Zavin <dima@android.com>
|
|
|
|
|
| |
Change-Id: I93f0e577aff6b8ff23a44e29f9942a26545b6dc8
Signed-off-by: Dima Zavin <dima@android.com>
|
|
|
|
|
| |
Change-Id: Iabdd2061cbc36c6f4d4eb6e46bd757b5b52e0027
Signed-off-by: Dima Zavin <dima@android.com>
|
|
|
|
|
| |
Bug: 5449033
Change-Id: I4951baa981f09a84ce483e3d1bd0f9ebe009035f
|
|
|
|
|
| |
Bug: 5449033
Change-Id: Ib453f869977a6e909095a578bbf0420851f887d2
|
|
Change-Id: Ifabeb75550fa6e351434e6e6d036b19331daf6c1
Signed-off-by: Dima Zavin <dima@android.com>
|