2c5e7e102b
It looks like there were a couple problems in the code: - It would not 0-terminate the string it read, to make sure we didn't see garbage at the end. - It didn't reduce buf_len as it processes data in the buffer, so if we need to read more we will increase the buffer length to be longer than the actual available data. Also put in some logs about every thing we kill, so we can see what is going on when debugging. And add a special check for us trying to kill pid 0 for any reason, since doing so seem to be terminal to the caller. Change-Id: I2fe29bfef08938b8a2eb182475c0705c14d8d84f
21 lines
669 B
Makefile
21 lines
669 B
Makefile
LOCAL_PATH := $(call my-dir)
|
|
|
|
include $(CLEAR_VARS)
|
|
LOCAL_SRC_FILES := processgroup.cpp
|
|
LOCAL_MODULE := libprocessgroup
|
|
LOCAL_SHARED_LIBRARIES := liblog libutils
|
|
LOCAL_C_INCLUDES := $(LOCAL_PATH)/include
|
|
LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/include
|
|
LOCAL_CFLAGS := -Wall -Werror
|
|
LOCAL_REQUIRED_MODULE := processgroup_cleanup
|
|
include external/libcxx/libcxx.mk
|
|
include $(BUILD_SHARED_LIBRARY)
|
|
|
|
include $(CLEAR_VARS)
|
|
LOCAL_SRC_FILES := cleanup.cpp
|
|
LOCAL_MODULE := processgroup_cleanup
|
|
LOCAL_C_INCLUDES := $(LOCAL_PATH)/include
|
|
LOCAL_CFLAGS := -Wall -Werror
|
|
LOCAL_FORCE_STATIC_EXECUTABLE := true
|
|
LOCAL_STATIC_LIBRARIES := libc libcutils
|
|
include $(BUILD_EXECUTABLE)
|