Go to file
Teddie Stenvi 8f5daadcc1 Fix ADB daemon file descriptor leak
The ADB (Android Debug Bridge) daemon suffers from a file descriptor leak.
When transfering file descriptors, opened by the adbd daemon, to a JDWP
process for debugging through sendmsg, the file descriptor is duplicated
by the kernel and a copy is transfered to the JDWP process.
Adbd neglects to close it's copy of the descriptor after the sendmsg call
which causes a file descriptor leak in the process.
Eventually this causes the daemon to hit its maximum roof of opened file
descriptors thus making it impossible for the process to serve any new
commands from the adb server.
Jdwp_service.c has been modified to close the file descriptor after the
send message call has succeded.
Also, the socket used for transfering the file descriptor is set to blocking
mode before the sendmsg call since the adbd processes needs to know when the
duplication has been completed by the kernel.
The flags are reset to its original state after the sendmsg call.

Change-Id: I76b15460301ac01e432f5ce8678ff58c658c16f2
Signed-off-by: Christian Bejram <christian.bejram@stericsson.com>
2010-06-18 08:11:04 +00:00
adb Fix ADB daemon file descriptor leak 2010-06-18 08:11:04 +00:00
cpio auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00
debuggerd debuggerd: Show function names in tombstone backtraces 2010-05-24 17:20:10 -05:00
fastboot resolved simple conflict with dc9cf66c 2010-01-21 18:06:39 -08:00
include init: Add support for /dev/bus/usb/ file system and add new unix group AID_USB. 2010-05-16 16:04:51 -04:00
init init: Add support for /dev/bus/usb/ file system and add new unix group AID_USB. 2010-05-16 16:04:51 -04:00
libacc Correctly compute the type of an assignment expression. 2009-11-09 12:52:45 +08:00
libctest Automated import from //branches/donutburger/...@140818,140818 2009-03-24 18:36:55 -07:00
libcutils am c1c38dd0: system: sched_policy: Don\'t return an error when the thread we\'re trying to move exits on us 2009-12-03 12:45:43 -08:00
liblinenoise Improve linenoise.c compatability. 2010-06-04 14:32:01 +08:00
liblog Fix Heap Corruption from too long of a TAG 2010-02-18 15:33:28 -06:00
libmincrypt only use faster SHA-1 code on machines with good libc 2009-08-21 11:08:25 -07:00
libnetutils libnetutils: Add ifc_enable(), for enabling a network interface. 2009-07-10 17:29:47 -04:00
libpixelflinger cpu-features.h is only available for ARM 2010-05-04 15:35:09 -07:00
libsysutils merge from open-source master 2009-10-14 08:19:24 -07:00
libzipfile Fix a call to memset(3) with reversed arguments. 2009-09-03 11:52:31 -07:00
logcat Add gsm_rat_switched event tag. 2010-01-13 18:28:15 -08:00
logwrapper Add a printf format. 2010-05-10 14:47:56 -07:00
mkbootimg fastboot, mkbootimg: support alternate base addresses 2009-04-28 16:05:07 -07:00
netcfg auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00
nexus nexus: Rollup update for nexus 2009-07-10 14:23:51 -07:00
rootdir Spell system correctly 2010-05-11 13:55:17 -05:00
sh Emit shell prompt even when in non-interactive mode. 2010-06-04 12:03:14 +08:00
toolbox toolbox-ls: sort file and directory lists 2010-06-04 10:44:56 -07:00
vold vold: fix a bug of crash 2010-03-25 14:28:03 +08:00
.gitignore Don't compile abort_socket.c for host targets. It is only intended to run on Linux targets. 2009-05-26 13:23:23 -07:00
Android.mk libsysutils: New C++ system convenience library 2009-05-06 15:12:02 -07:00
README auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00

README

The system/ directory is intended for pieces of the world that are the
core of the embedded linux platform at the heart of Android.  These
essential bits are required for basic booting, operation, and debugging.

They should not depend on libraries outside of system/... (some of them
do currently -- they need to be updated or changed) and they should not
be required for the simulator build.

The license for all these pieces should be clean (Apache2, BSD, or MIT).

Currently system/bluetooth/... and system/extra/... have some pieces
with GPL/LGPL licensed code.

Assorted Issues:

- pppd depends on libutils for logging
- pppd depends on libcrypt/libcrypto
- init, linker, debuggerd, toolbox, usbd depend on libcutils
- should probably rename bionic to libc