Commit Graph

1708 Commits

Author SHA1 Message Date
Mike Lockwood d37e0840d7 Merge "In serial, skip over port as well if numbers found after colon." 2011-04-06 07:25:31 -07:00
Terence Haddock e994f18c53 In serial, skip over port as well if numbers found after colon.
Change-Id: Icd45f570a9527790eb0cd614a3f77da1a72375b1
2011-04-06 16:18:25 +02:00
Brad Fitzpatrick 7c55654907 Merge changes Icdefb5ff,Icd7f5f03
* changes:
  Fix potential race introduced in Icd7f5f03
  SocketClient: add optional reference counting
2011-03-23 11:57:49 -07:00
Brad Fitzpatrick 499b45a359 Merge "libsysutils: Fix a file descriptor leak." 2011-03-23 11:57:30 -07:00
Brad Fitzpatrick 4593e0a764 Merge "libsysutils: Fix race condition in SocketListener thread." 2011-03-23 11:56:52 -07:00
Brad Fitzpatrick 0e59123ada Merge "libsysutils: Handle EINTR in SocketClient::sendData()" 2011-03-23 11:56:50 -07:00
Brad Fitzpatrick 3549b0dc28 Fix potential race introduced in Icd7f5f03
Digit wrote:

"You probably don't want to close the socket here without updating
c->socket as well. Otherwise, another thread holding a handle to the
client after the c->decRef() could end up sending a message to a
different socket, if the file descriptor index is reused by another
client in the meantime."

Change-Id: Icdefb5ffc0c7607325d7db761e1f04e5d868bfb7
2011-03-22 14:03:11 -07:00
Brad Fitzpatrick 13aa8ad445 SocketClient: add optional reference counting
Needed to fix a race in netd.

Bug: 3438459
Change-Id: Icd7f5f035510235f733a25c0621479d3e644b152
2011-03-22 14:03:08 -07:00
David 'Digit' Turner 15d09854a8 libsysutils: Fix a file descriptor leak.
The recent refactoring of the select() loop in SocketListener
missed a close() of the file descriptor when the onDataAvailable()
callback returns false.

Change-Id: I767caefab4b98ab350f2db2497ee2bd630f20850
2011-03-22 14:03:04 -07:00
David 'Digit' Turner 100c0e2dab libsysutils: Fix race condition in SocketListener thread.
+ Handle EINTR in accept(), write() and select()
+ Fix a memory leak when deleting the mClients list
+ Fix typo in SocketListener.h

Change-Id: Ie68bb3e2dbefe0dfdaa22a5cd06a42dbc4c0f8aa
2011-03-22 14:02:51 -07:00
David 'Digit' Turner 01feae2d7c libsysutils: Handle EINTR in SocketClient::sendData()
+ Improve allocation code in sendMsg(code,msg,addErrno)

Change-Id: Ib5fe84bec1a167c369e7ba759acea395e832f6b5
2011-03-22 14:02:18 -07:00
David Turner e6b638be19 Merge "x86: Add vold.fstab to mount the SD card" 2011-03-02 06:06:55 -08:00
Raphael Moll fa5f2ad48b am bd8f4a85: Merge "Define O_BINARY for non-Windows platforms."
* commit 'bd8f4a85ce45649dc75fbef139f0deae12f834a7':
  Define O_BINARY for non-Windows platforms.
2011-03-01 12:41:32 -08:00
Raphael Moll bd8f4a85ce Merge "Define O_BINARY for non-Windows platforms." 2011-02-22 14:36:28 -08:00
Raphael Moll bd70e4aca5 Define O_BINARY for non-Windows platforms.
All tools (aapt, aidl, dexdump, etc.) need this flag to open()
binary files, or they risk reading corrupted data on Windows.

A bunch of these tools just conditionaly define O_BINARY in
their C files. Seems it would just make sense to define it globally.

Change-Id: Ia5c0a59e9e77bbdcbce235233555f611207abed8
2011-02-16 13:36:42 -08:00
Jun Nakajima 0db0921b59 x86: Add vold.fstab to mount the SD card
Change-Id: Ie1f70a22dd4e27e8ea956d5e627877d1e2379b95
Signed-off-by: Jun Nakajima <jun.nakajima@intel.com>
2011-02-13 21:10:40 -08:00
Mike Lockwood d4894f4be6 am 034117e4: Merge changes I8df51128,Ie922b3e7,I31f78419,I7e8df44d,I6067857b,Ifd35587c,Ie8d66740
* commit '034117e47f2601d46563461a0bfe3cc22f89a0f0':
  Fix adb leaking file descriptors to forked processes
  adb: Fix command-line parser.
  adb: Increase device descriptor buffer size in Linux host USB support
  adb: improve debug traces readability.
  adb: Don't report negative number of bytes after pushing file > 2 gigabytes
  Adding Texas Instruments to the VID list.
  Support an additional alias for 'adb shell.'
2011-02-03 12:56:57 -08:00
Mike Lockwood 034117e47f Merge changes I8df51128,Ie922b3e7,I31f78419,I7e8df44d,I6067857b,Ifd35587c,Ie8d66740
* changes:
  Fix adb leaking file descriptors to forked processes
  adb: Fix command-line parser.
  adb: Increase device descriptor buffer size in Linux host USB support
  adb: improve debug traces readability.
  adb: Don't report negative number of bytes after pushing file > 2 gigabytes
  Adding Texas Instruments to the VID list.
  Support an additional alias for 'adb shell.'
2011-02-03 12:34:38 -08:00
Benoit Goby 3b4a0c81c4 Fix adb leaking file descriptors to forked processes
accept() creates a new file descriptor that should be closed on exec so
that forked processes don't keep a fd opened on the socket.

This also fixes b/3297070 where adb hangs after running adb on the
target.

Change-Id: I8df511289e5549ae49b4824c9dfb71a3bf85eae8
2011-02-03 15:26:45 -05:00
David 'Digit' Turner eb5df470e6 adb: Fix command-line parser.
This fixes the command-line parser to accept both "daemon server"
and "server nodaemon". Before the patch, the second string would
ignore the "nodaemon" flag.

Fixes b/2191598

Change-Id: Ie922b3e7bf57a6e334fc448cec33fb340ca6abc4
2011-02-03 15:26:43 -05:00
Mike Lockwood a5d4694846 adb: Increase device descriptor buffer size in Linux host USB support
256 bytes wasn't big enough for some complicated USB configurations

Change-Id: I31f7841953d73b06958f44040f58166b159faff4
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-03 15:26:41 -05:00
David 'Digit' Turner 3e42db23fb adb: improve debug traces readability.
This patch makes the traces easier to read. For example transports are
displayed by name/serial instead of their hex address.

Change-Id: I7e8df44ddbec19754d63d989bd56485998b4627b
2011-02-03 15:26:37 -05:00
Mike Lockwood 487009ef5e adb: Don't report negative number of bytes after pushing file > 2 gigabytes
BUG: 3198322

Change-Id: I6067857b9490984a21b597f6ee338446a9decaf5
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-03 15:26:35 -05:00
Alex Sakhartchouk 1d3fbed348 Adding Texas Instruments to the VID list.
Change-Id: Ifd35587c93ae7d5c8253f477a92cca2345dc8bb5
2011-02-03 15:26:33 -05:00
Daniel Sandler 9c73d17e87 Support an additional alias for 'adb shell.'
Change-Id: Ie8d667407fef8ee5a6c7ab86b30307fb61869170
2011-02-03 15:26:29 -05:00
Brad Fitzpatrick 63e70b2428 am 4585e0e9: Merge changes I087d0074,I8a51924e
* commit '4585e0e9f76e2c51a7f4a9679ec8b8d25f9b5e63':
  Permit 0 length writes.
  Let SocketClient users write binary data to clients.
2011-01-25 15:44:19 -08:00
Brad Fitzpatrick 4585e0e9f7 Merge changes I087d0074,I8a51924e
* changes:
  Permit 0 length writes.
  Let SocketClient users write binary data to clients.
2011-01-25 15:13:28 -08:00
Jean-Baptiste Queru 55dc9744c9 am cdeba125: Merge "Assembly coded android_memset16 and android_memset32"
* commit 'cdeba1258b511b6df450221bcfb2572e5523558a':
  Assembly coded android_memset16 and android_memset32
2011-01-07 15:34:04 -08:00
Jean-Baptiste Queru f5cb0a1385 am fc0b4ff1: Merge "init: Fix parser line numbering"
* commit 'fc0b4ff1c8675be3626510a5adfbcae507ecfa43':
  init: Fix parser line numbering
2011-01-07 15:34:03 -08:00
Jean-Baptiste Queru cdeba1258b Merge "Assembly coded android_memset16 and android_memset32" 2011-01-07 11:23:07 -08:00
Jean-Baptiste Queru fc0b4ff1c8 Merge "init: Fix parser line numbering" 2011-01-07 11:14:59 -08:00
Brad Fitzpatrick b9634d05cf Permit 0 length writes.
Change-Id: I087d0074c8d9e13ce814187475966da94f693fc0
2011-01-06 11:16:15 -08:00
Brad Fitzpatrick a2a1f3149f Let SocketClient users write binary data to clients.
This is a dependency for the DNS proxy CLs.

This CL also adds a new socket for the netd process to inherit which
is owned by the inet group.  (so only apps with the INTERNET
permission can use the DNS proxy...)

Change-Id: I8a51924e0ed56c6066f77e6f1b02d39bdadac51e
2011-01-06 11:09:55 -08:00
Colin Cross bf10797e53 am f7ca6040: Fix infinite loop in init when debugging is turned off
* commit 'f7ca6040616f672a6f0039d55e39c610b7c1cf91':
  Fix infinite loop in init when debugging is turned off
2011-01-04 18:49:07 -08:00
Colin Cross f7ca604061 Fix infinite loop in init when debugging is turned off
If a keychord is pressed when debugging is turned off, the main
event poll in init will return an event on the keychord fd,
but handle_keychord never reads the data.  Once this happens,
the poll will always return immediately, and init enters an
infinite loop.  Fix it by always reading from the keychord fd,
but only handling the returned keychord if debugging is
enabled.

Change-Id: Ie4efa98247d3cc978d275dc8a4516b32aa710278
2011-01-04 18:21:22 -08:00
Bruce Beare d7a295221a Assembly coded android_memset16 and android_memset32
Change-Id: Ifa05006df7ce7364d18eb10d64a818d619664475
Author: Lu, Hongjiu <hongjiu.lu@intel.com>
Signed-off-by: Mark Gross <mark.gross@intel.com>
Signed-off-by: Bruce Beare <bruce.j.beare@intel.com>
2011-01-02 17:00:09 -08:00
Bruce Beare 378083a3f0 init: Fix parser line numbering
Change-Id: I3885dd7d631e7330d92780df822b3ee1a8d0350b
Signed-off-by: Bruce Beare <brucex.j.beare@intel.com>
2011-01-02 17:00:08 -08:00
Jean-Baptiste Queru f1c2a7352f Merge "fastboot: Add help message for continue command" 2010-12-29 13:12:10 -08:00
Bruce Beare 24ce4bc8d7 fastboot: Add help message for continue command
Change-Id: I578b1b7c2d74d09d44ce9100bfe582aaa25c31b1
Signed-off-by: Bruce Beare <bruce.j.beare@intel.com>
2010-12-29 13:11:53 -08:00
Jean-Baptiste Queru 660c8b7195 am cbb9257a: Merge "Fix debuggerd (native crash dump)."
* commit 'cbb9257a872a0f35b0aa1018410ca6025e628c36':
  Fix debuggerd (native crash dump).
2010-12-14 13:32:45 -08:00
Jean-Baptiste Queru cbb9257a87 Merge "Fix debuggerd (native crash dump)." 2010-12-14 13:21:11 -08:00
Mike Dodd 0b4836f2cd Fix debuggerd (native crash dump).
Change 44659e90f (6cc4923087 in AOSP) introduced walking
both the symbol table and dynamic symbol table. The problem
is that it was dereferencing values whether or not the two tables
were both present, which could wind up reading from invalid memory.
The read from a bad address would cause debuggerd itself to crash,
which isn't handled.

Change-Id: Ie936f660018b1980dee5b6ed669588db861f1a79
2010-12-14 13:15:47 -08:00
Jean-Baptiste Queru 44659e90fe am d3f59eab: Merge "debuggerd: IA version"
* commit 'd3f59eab07d102b9506978aca9541dd62dcea919':
  debuggerd: IA version
2010-12-13 11:37:40 -08:00
Jean-Baptiste Queru d3f59eab07 Merge "debuggerd: IA version" 2010-12-13 11:32:21 -08:00
Jean-Baptiste Queru 144773f9e1 am e382cc99: Merge "debuggerd: Reorganize to facilitate IA commit"
* commit 'e382cc999e48b3faabea7743ec8cec303b6005ba':
  debuggerd: Reorganize to facilitate IA commit
2010-12-13 11:14:26 -08:00
Jean-Baptiste Queru e382cc999e Merge "debuggerd: Reorganize to facilitate IA commit" 2010-12-13 10:48:08 -08:00
Bruce Beare 6cc4923087 debuggerd: IA version
Change-Id: I0c0d9c2d7e476b8d117aaf505a9480a47c0b5c05
Signed-off-by: Lei Li <lei.l.li@intel.com>
Signed-off-by: Bruce Beare <bruce.j.beare@intel.com>
2010-11-29 11:28:11 -08:00
Bruce Beare 849249064c debuggerd: Reorganize to facilitate IA commit
Change-Id: I22dd02daf617672fc0a8ba7e396017c57f17e26e
Signed-off-by: Bruce Beare <bruce.j.beare@intel.com>
2010-11-29 11:03:48 -08:00
Jean-Baptiste Queru 8f461e5cc2 resolved conflicts for merge of 1a15cb7e to gingerbread-plus-aosp
Change-Id: I6468f995c29c6e05f4cb89bedb02cff2ff4bac61
2010-11-24 08:41:41 -08:00
Jean-Baptiste Queru 1a15cb7e90 Merge "[PATCH] Init - make sure the last parameter to execve is NULL" 2010-11-24 08:27:17 -08:00