OSDN Git Service

pdx_benchmarks: Let the service create sockets by itself
authorAlex Vakulenko <avakulenko@google.com>
Mon, 17 Apr 2017 23:19:51 +0000 (16:19 -0700)
committerAlex Vakulenko <avakulenko@google.com>
Wed, 19 Apr 2017 19:30:07 +0000 (12:30 -0700)
commit7038c239728012789855f121e98baf0df0d81087
tree76dad374e36c5bad82922e289fc53ba1db1a8748
parentd618b567630d347be0929ea25ce6c68921005ed6
pdx_benchmarks: Let the service create sockets by itself

Default implementation of Endpoint::Create() takes the socket name
as provided by the init process when it forks. pdx_benchmark is not
a service but a command-line utility and it is being started manually
and not through init process. So, named sockets are not available.
Instead, it must create a socket by the specified name. For this,
it must use Endpoint::CreateAndBindSocket() method.

Bug: 37507039
Test: Tested manually on device: `pdx_benchmarks --service foo`.
Change-Id: If30bfa7138f5a97ba0bff9e61460c6bd3697ec19
libs/vr/libpdx_default_transport/pdx_benchmarks.cpp