Age | Commit message (Collapse) | Author |
|
Allow callers to remove a tracked pid if tracking is
no longer desired (e.g., if the caller has reaped the
process themselves.)
BUG=chromium:535910
Change-Id: Ie056c54a66c5aed539d2a77a41135f9b2da66582
|
|
On branches where DBus is not available we need to disable the
compilation of all the targets requiring DBus.
Bug: 25197634
Test: `mmma external/libbrillo` with the BRILLO_USE_DBUS := 0 in the .mk
Test: FEATURES=test emerge-link libbrillo
Change-Id: I4924c93e65ef14c732eea6ee7a73beb118538585
|
|
Now that the former libchromeos repo sources are checked out at
external/libbrillo, update the include path for intermediates generated
for protobufs.
BUG: 24872993
Change-Id: I7e3dc205837e69c6ab355ea8b6dfc50ab22e0d24
|
|
Renamed libchromeos[-.*] libraries into libbrillo-...
BUG: 24872993
Change-Id: Ibab1623b6a08a55cae3662e941d0d6644ff14df4
|
|
Apparently some of the unit tests for libchromeos weren't being
compiled on Brillo/Android. Add them to the make file and make
a few tweaks to make sure they compile successfully.
Change-Id: I324d4bb0b89ac96e564cd107a5bb3751ebd4b9ae
|
|
The expected error message relied too much on demangling of std::string.
On Android, it shows as std::__1::basic_string<...>. So just use a
rough regex to match the error message but do not use it verbatim.
Change-Id: I2c6c7810bf028118cf2ebeb7bd04f47d1da835e5
|
|
Any normally embeds small data objects (with the size of up to
double). This test verifies that larger objects are stored externally.
However 10 bytes is not large enough and on some platform due to data
alignment/padding a bit larger data than that of double can still be
stored inside Any itself. Use 20 bytes to guarantee that Any cannot
contain the buffer of that size inside.
Change-Id: Iceaa0efbc74570f17d2cc70aa8d6537cc8bd2be5
|
|
std::type_info::operator==() uses pointers to type names on some
implementations (e.g. gcc with __GXX_MERGED_TYPEINFO_NAMES defined).
This leads to problems such that types created in different translation
units could be treated as different even though they refer to the
same type.
Working with type_info directly seems unreliable and names of the
types should be used in comparisons directly.
Fixed the implementation of Any::IsTypeCompatible<T>() to use type
names and remove Any::GetType() to avoid any future problems for
client code to compare the type information manually.
Added Any::GetTypeName() and Any::GetUndecoratedTypeName() for
convenience.
BUG: 25132472
Change-Id: I8ba27a611c8edad2260dbed1c2f15633c8b3a3fe
|
|
Test protobufs need to be generated in "brillo" directory now, not
in "chromeos" to match the include paths.
BUG: 24872993
Change-Id: Ib04473b1395f67fead866e2d0e478835b904fb75
|
|
When building for Android, do not use the minijail_run_pid_pipe* API
funtions that use LD_PRELOAD. Instead, use the *_no_preload versions
of these functions.
While there, replace the use of minijail_run_pid_pipe() with
minijail_run_pid_pipes().
BUG: 24577038
Change-Id: Ie29a0f762e7810587f49199679dcc9d90acd465d
TEST: unit tests pass.
|
|
daemon.cc has these renamed, but not daemon.h. Not sure how this
compiled locally.
Change-Id: Ia7efed2764dc1d8580cfa9f16518459ec3732be6
|
|
And move the include files into "brillo" directory instead of "chromeos"
BUG: 24872993
TEST=built aosp and brillo and unit tests pass on dragonoboard
Change-Id: Ieb979d1ebd3152921d36cd15acbd6247f02aae69
|
|
BUG: 24585672
TEST: compiles. Unit tests pass.
Change-Id: I7d84a673c85ba8955e03598f2fe4577de7ad5fef
|
|
Adding tag debug, now tests will be built in
Brillo eng/userdebug makes.
Change-Id: Ib4b7891d965f484e10b110c911cf4308a1113a1c
|
|
|
|
This reverts commit 2f5e1dcf721f85bb86ad9079cf3838b52540e3a9.
Change-Id: Ie81210fab88ee4ef35139ef64fdc9a61ba0a42fa
|
|
"Uninterested" doesn't mean what you think it means.
Bug: None
Change-Id: If697cc5050b9dc729f80c884737af998f0f94611
|
|
Adding tag debug, now tests will be built in eng/userdebug makes.
Change-Id: I6ed5a77a7a95f316b9da5e9e83bb74a064fea8ce
|
|
|
|
This CL adds the support for the newly added GetAndBlock function
in libchrome dbus library.
This will allow us to use a synchronous version of PropertySet::Get.
Bug: 24131409
TEST=run tests on a veyron_jaq chromebook
Change-Id: I926e480c14ff2627fdad5351e438e86a03a721aa
|
|
Adjust the libchromeos-host build so that it doesn't include the
components that rely on Linux-specific signalfd() and openat()
functionality.
For the error number list, don't include Linux-specific errors.
Finally replace setresuid() and setresgid() with setreuid() and
setregid() on non-Linux platforms.
BUG=24073089
TEST=libchromeos-host builds on Mac,
dbus-binding-generator builds and runs on a Mac host,
peerd's build uses dbus-binding-generator on a Mac host.
Change-Id: Ic68a097d9a007c3392fcdb88b48ed8b27563e45a
|
|
|
|
Now that minijail and libchrome are built on non-Linux, this isn't
needed.
BUG=24073089
TEST=mm on a mac
Change-Id: I247ac9c0ba38d86919312fe8a0c563fd520c45fb
|
|
This is a useful utility function to copy data from one stream
into another. It can be used in a variety of cases, e.g. reading
data from a stream into memory - create memory stream and copy data
from source stream into it.
Change-Id: Iccdd29966efaf76b90f5d89faa5bfbf80e8586f3
|
|
This CL adds the support for the newly added SetAndBlock function
in libchrome dbus library.
This will allow us to use a synchronous version of PropertySet::Set.
Bug: 24131409
TEST=run tests on a veyron_jaq chromebook
Change-Id: I1bf14e187e69fbc128bb0c696557575fbf6f22fa
|
|
A CL (https://android-review.googlesource.com/#/c/169912) added extra
call to get the status code of request for logging which broke
HttpCurlTransportAsyncTest.StartAsyncTransfer due to an unexpected
method call of a mock.
Also, FileStreamTest.FromFileDescriptor_WriteNonBlocking took over
4 seconds on dragonboard and there is no real reason to create
a 10 MB buffer to test pipes which use only 64K. Reducing the buffer
size brought the test execution time to 136 ms.
BUG: 23942116
Change-Id: Ib0bc5ac6ffc7bd96ef3946c31d0cda283756bd82
|
|
|
|
Add a class that bridges between base::MessageLoop and
libbinder. When instantiated, the binder FD will be watched
and libbinder will be notified about transactions.
Change-Id: If68d2765fa5161196489c4004360f2d0c56e59d0
|
|
When analyzing production logs (with log level = 0/INFO) it is difficult
to judge when HTTP request succeed or fail. With --v=2 enabled, all of
this is provided, but this is not good for production devices and their
logs.
Added request/response tracking messages to LOG(INFO) level to make
log analysis easier.
BUG: 23791756
Change-Id: Ie3bf48d45d6facb02a6d26176d10a5612d4e683b
|
|
BUG: 23817518
Change-Id: I9178adb56b888a2151f2290d18a20671fc663fed
TEST: unit tests.
|
|
Change-Id: I6ab9170b8f1e434fc5c21fb1850ee9a8165ae8ea
|
|
The Android.mk file had this file missing from the library.
Bug: 23817518,23084776
Change-Id: I0ef98fdd4da6d196f483a702cd76aaa058b288f0
Test: `mma -B` on libchromeos; update_engine now links agains libchromeos.
|
|
libpolicy unittests used the old 'chromeos/policy' location instead of
just 'policy' for their includes. This patch fixes the path according
to the new location.
Bug: 23555535
TEST=mma; FEATURES=test emeger-link libchromeos
Change-Id: I300a686b82e9bedf6c3151a4b7fa5b1c10ef41d3
|
|
libpolicy is installed directly as "policy" in Chrome OS, so this patch
moves the chromeos/policy directory one level up to match what users will
see in installed Chrome OS include dir. A new libchromeos-policy shared
library is included in the Android.mk.
BUG: 23555535
TEST=emerge-link libchromeos; `mm` in aosp.
Change-Id: I0d62a1651632242a08309ca2c00056837a5280a6
|
|
|
|
libchromeos-ui is moving back to src/platform2 as it is only used on
chromeos.
BUG=chromium:525211
TEST=manual: `emerge-gizmo libchromeos` does not install libchromeos-ui.
TEST=trybots.
Change-Id: Id16af4b9f4aa090ef2c9805f6e963773bd62a881
|
|
libchromeos-dbus header files (such as dbus_daemon.h) include header
files from the dbus library, so if someone uses libchromeos-dbus it
needs to include dbus's include dirs.
This patch exposes dbus include dir to libchromeos-dbus users.
Bug: 23084776
TEST=mma in update_engine
Change-Id: I7ce3ffabdd3296553c846b54b8d1a592cd4ba3db
|
|
|
|
BUG=chromium:521249
TEST=emerge-lumpy libchromeos, verify cmdline is added
Change-Id: I9694fb465715bcaf29d9dcfc07a9b21b7ede8e9f
|
|
This is needed for supporting cellular modem proxies in shill.
While there, use std::tuple instead of std::pair for deserializing struct
variant type.
BUG=chromium:517680
TEST=build libchromeos
TEST=Run network_3GSmokeTest on device with shill using libchromeos dbus
Change-Id: I6c138ee4a52c2655143929c70d6958d6aff3b05f
|
|
|
|
__ANDROID__ is defined automatically by the toolchain.
Bug: 23358460
Change-Id: I125d56638f06f0eb10ba0cde147ab835522959f1
|
|
The certificates are stored at /system/etc/security/cacerts on Brillo
BUG: 23352819
Change-Id: I0ed8a084bb8597671fffd33b03f3d5b5dc01f52c
|
|
(cherry-picked from
https://chromium.googlesource.com/a/chromiumos/platform2 at
7b4a3084d80b9d8e539787639ede95f9ad760948)
Some packages use minijail by including only libchromeos (which includes
libchromeos-minijail).
In this case, libchromeos must export libminijail in the pkgconfig file
in order for the include path to be set correctly.
BUG=None
TEST=trybots.
Change-Id: I818386c63fe9006982b640d7cbdd2238d223646d
Reviewed-on: https://chromium-review.googlesource.com/293811
Trybot-Ready: Bertrand Simonnet <bsimonnet@chromium.org>
Tested-by: Bertrand Simonnet <bsimonnet@chromium.org>
Reviewed-by: Alex Deymo <deymo@chromium.org>
Commit-Queue: Bertrand Simonnet <bsimonnet@chromium.org>
Reviewed-by: Jorge Lucangeli Obes <jorgelo@chromium.org>
|
|
(cherry-picked from
https://chromium.googlesource.com/a/chromiumos/platform2 at
50fb55a05efdd0b31dc8dcbb53591bfff68f8703)
This allows us to change the import path of libminijail.h easily.
BUG=None
TEST=`emerge-gizmo apmanager attestation cromo cros-disks debugd
libchromeos lorgnette minijail tpm_manager trunks webserver` works.
CQ-DEPEND=CL:293580
Change-Id: I96a98d9f268fab518c2cc34c3d2ce2c5ae07788b
Reviewed-on: https://chromium-review.googlesource.com/293483
Reviewed-by: Bertrand Simonnet <bsimonnet@chromium.org>
Commit-Queue: Bertrand Simonnet <bsimonnet@chromium.org>
Trybot-Ready: Bertrand Simonnet <bsimonnet@chromium.org>
Tested-by: Bertrand Simonnet <bsimonnet@chromium.org>
|
|
|
|
(cherry-picked from
https://chromium.googlesource.com/a/chromiumos/platform2 at
3f609aba265a91634b5af226ceac9783beac6b36)
When more than once source of events (file descriptor available or
delayed task ready) is available, the MessageLoop has some freedom to
schedule between I/O tasks and delayed tasks. The
base::MessageLoopForIO will not dispatch posted delayed tasks if there
are file descriptors indefinitely available and will prefer to allways
run all the I/O callbacks before running the delayed tasks that are
due, causing what is known as starvation.
In the Chrome context, this is not a big problem since the thread
running the base::MessageLoopForIO normally posts delayed tasks to
other threads. Even with a single CPU, it is sufficient to have a fair
thread scheduler to avoid starvation. In the Chrome OS context of
single threaded daemons doing I/O, this is more important.
This patch tightens the contract on chromeos::MessageLoop API to
prevent starvation. The chromeos::GlibMessageLoop implementation
already ensures this property, so we fix the chromeos::BaseMessageLoop
by posting a task to the message loop when a file descriptor is ready
and stop watching that file descriptor while the task is waiting in the
message loop.
New unittest are included here to verify the same behaviour over both
implementations.
BUG=chromium:419827
TEST=Added unittest.
Change-Id: Ibc0aa999b9e86e6e3205d71ece3a7b72e019b6a3
Reviewed-on: https://chromium-review.googlesource.com/293334
Reviewed-by: Alex Vakulenko <avakulenko@chromium.org>
Trybot-Ready: Alex Deymo <deymo@chromium.org>
Tested-by: Alex Deymo <deymo@chromium.org>
Commit-Queue: Alex Deymo <deymo@chromium.org>
|
|
|
|
|
|
This reverts commit 5d7fc29f9f5a9c9858f3df2395eed31abe72c5a7.
Change-Id: I107ad70a4bbeb5dccf0ac303936b7eadef645583
|