/system/connectivity/shill/ |
D | property_accessor_unittest.cc | 41 Error error; in TEST() local 44 EXPECT_EQ(int_store, accessor->Get(&error)); in TEST() 47 EXPECT_TRUE(accessor->Set(expected_int32, &error)); in TEST() 48 EXPECT_TRUE(error.IsSuccess()); in TEST() 49 EXPECT_EQ(expected_int32, accessor->Get(&error)); in TEST() 52 EXPECT_FALSE(accessor->Set(expected_int32, &error)); in TEST() 53 EXPECT_TRUE(error.IsSuccess()); in TEST() 55 accessor->Clear(&error); in TEST() 56 EXPECT_TRUE(error.IsSuccess()); in TEST() 57 EXPECT_EQ(orig_value, accessor->Get(&error)); in TEST() [all …]
|
D | property_accessor.h | 66 void Clear(Error* error) override { Set(default_value_, error); } in Clear() argument 90 void Clear(Error* error) override { in Clear() argument 93 error->Populate(Error::kInvalidArguments, "Property is read-only"); in Clear() 96 bool Set(const T& /*value*/, Error* error) override { in Set() argument 99 error->Populate(Error::kInvalidArguments, "Property is read-only"); in Set() 117 void Clear(Error* error) override { Set(default_value_, error); } in Clear() argument 118 T Get(Error* error) override { in Get() argument 119 error->Populate(Error::kPermissionDenied, "Property is write-only"); in Get() 158 T(C::*getter)(Error* error), in CustomAccessor() argument 159 bool(C::*setter)(const T& value, Error* error), in CustomAccessor() [all …]
|
D | device_claimer_unittest.cc | 54 Error error; in TEST_F() local 56 EXPECT_TRUE(device_claimer_.Claim(kTestDevice1Name, &error)); in TEST_F() 57 EXPECT_EQ(Error::kSuccess, error.type()); in TEST_F() 62 error.Reset(); in TEST_F() 64 EXPECT_TRUE(device_claimer_.Claim(kTestDevice2Name, &error)); in TEST_F() 65 EXPECT_EQ(Error::kSuccess, error.type()); in TEST_F() 72 error.Reset(); in TEST_F() 74 EXPECT_FALSE(device_claimer_.Claim(kTestDevice1Name, &error)); in TEST_F() 75 EXPECT_EQ(string(kDuplicateDevice1Error), error.message()); in TEST_F() 79 error.Reset(); in TEST_F() [all …]
|
D | service_property_change_test.cc | 50 Error error; in TestCommonPropertyChanges() local 67 service->SetGuid("some garbage", &error); in TestCommonPropertyChanges() 79 service->SetPriority(1, &error); in TestCommonPropertyChanges() 82 EXPECT_EQ(string(), service->GetProxyConfig(&error)); in TestCommonPropertyChanges() 84 service->SetProxyConfig("some garbage", &error); in TestCommonPropertyChanges() 100 service->error()); in TestCommonPropertyChanges() 107 service->error()); in TestCommonPropertyChanges() 115 service->error()); in TestCommonPropertyChanges() 132 Error error; in TestNamePropertyChange() local 133 string name = service->GetNameProperty(&error); in TestNamePropertyChange() [all …]
|
D | technology_unittest.cc | 78 Error error; in TEST_F() local 81 "", &technologies, &error)); in TEST_F() 83 EXPECT_TRUE(error.IsSuccess()); in TEST_F() 86 "ethernet", &technologies, &error)); in TEST_F() 88 EXPECT_TRUE(error.IsSuccess()); in TEST_F() 91 "ethernet,vpn", &technologies, &error)); in TEST_F() 94 EXPECT_TRUE(error.IsSuccess()); in TEST_F() 97 "wifi,ethernet,vpn", &technologies, &error)); in TEST_F() 101 EXPECT_TRUE(error.IsSuccess()); in TEST_F() 107 Error error; in TEST_F() local [all …]
|
D | key_file_store.cc | 47 string ConvertErrorToMessage(GError* error) { in ConvertErrorToMessage() argument 48 if (!error) { in ConvertErrorToMessage() 52 base::StringPrintf("GError(%d): %s", error->code, error->message); in ConvertErrorToMessage() 53 g_error_free(error); in ConvertErrorToMessage() 91 GError* error = nullptr; in Open() local 97 &error)) { in Open() 101 << ConvertErrorToMessage(error); in Open() 114 GError* error = nullptr; in Flush() local 116 gchar* data = g_key_file_to_data(key_file_, &length, &error); in Flush() 119 if (!data || error) { in Flush() [all …]
|
D | static_ip_parameters.h | 101 void ClearMappedProperty(const size_t& index, Error* error); 102 void ClearMappedSavedProperty(const size_t& index, Error* error); 103 int32_t GetMappedInt32Property(const size_t& index, Error* error); 104 int32_t GetMappedSavedInt32Property(const size_t& index, Error* error); 105 std::string GetMappedStringProperty(const size_t& index, Error* error); 106 std::string GetMappedSavedStringProperty(const size_t& index, Error* error); 107 std::string GetMappedStringsProperty(const size_t& index, Error* error); 108 std::string GetMappedSavedStringsProperty(const size_t& index, Error* error); 110 const size_t& index, const int32_t& value, Error* error); 112 const size_t& index, const int32_t& value, Error* error); [all …]
|
/system/connectivity/apmanager/ |
D | config_unittest.cc | 149 void VerifyError(const Error& error, in VerifyError() argument 152 EXPECT_EQ(expected_type, error.type()); in VerifyError() 153 EXPECT_TRUE(base::StartsWith(error.message(), expected_message_start, in VerifyError() 188 Error error; in TEST_F() local 190 EXPECT_TRUE(config_->ValidateSsid(&error, "s")); in TEST_F() 191 EXPECT_TRUE(config_->ValidateSsid(&error, std::string(32, 'c'))); in TEST_F() 192 EXPECT_FALSE(config_->ValidateSsid(&error, "")); in TEST_F() 193 EXPECT_FALSE(config_->ValidateSsid(&error, std::string(33, 'c'))); in TEST_F() 197 Error error; in TEST_F() local 198 EXPECT_TRUE(config_->ValidateSecurityMode(&error, kSecurityModeNone)); in TEST_F() [all …]
|
/system/update_engine/ |
D | dbus_service.cc | 34 bool DBusUpdateEngineService::AttemptUpdate(ErrorPtr* error, in AttemptUpdate() argument 38 error, in_app_version, in_omaha_url, 0 /* no flags */); in AttemptUpdate() 42 ErrorPtr* error, in AttemptUpdateWithFlags() argument 52 error, in_app_version, in_omaha_url, in AttemptUpdateWithFlags() 56 bool DBusUpdateEngineService::AttemptRollback(ErrorPtr* error, in AttemptRollback() argument 58 return common_->AttemptRollback(error, in_powerwash); in AttemptRollback() 61 bool DBusUpdateEngineService::CanRollback(ErrorPtr* error, in CanRollback() argument 63 return common_->CanRollback(error, out_can_rollback); in CanRollback() 66 bool DBusUpdateEngineService::ResetStatus(ErrorPtr* error) { in ResetStatus() argument 67 return common_->ResetStatus(error); in ResetStatus() [all …]
|
D | common_service.h | 47 bool AttemptUpdate(brillo::ErrorPtr* error, 52 bool AttemptRollback(brillo::ErrorPtr* error, bool in_powerwash); 56 bool CanRollback(brillo::ErrorPtr* error, bool* out_can_rollback); 60 bool ResetStatus(brillo::ErrorPtr* error); 65 bool GetStatus(brillo::ErrorPtr* error, 73 bool RebootIfNeeded(brillo::ErrorPtr* error); 83 bool SetChannel(brillo::ErrorPtr* error, 91 bool GetChannel(brillo::ErrorPtr* error, 97 bool SetP2PUpdatePermission(brillo::ErrorPtr* error, bool in_enabled); 101 bool GetP2PUpdatePermission(brillo::ErrorPtr* error, bool* out_enabled); [all …]
|
D | dbus_service.h | 42 bool AttemptUpdate(brillo::ErrorPtr* error, 46 bool AttemptUpdateWithFlags(brillo::ErrorPtr* error, 51 bool AttemptRollback(brillo::ErrorPtr* error, bool in_powerwash) override; 55 bool CanRollback(brillo::ErrorPtr* error, bool* out_can_rollback) override; 59 bool ResetStatus(brillo::ErrorPtr* error) override; 64 bool GetStatus(brillo::ErrorPtr* error, 72 bool RebootIfNeeded(brillo::ErrorPtr* error) override; 82 bool SetChannel(brillo::ErrorPtr* error, 90 bool GetChannel(brillo::ErrorPtr* error, 96 bool SetP2PUpdatePermission(brillo::ErrorPtr* error, [all …]
|
/system/connectivity/shill/vpn/ |
D | third_party_vpn_driver_unittest.cc | 98 Error error; in TEST_F() local 99 driver_->Connect(service_, &error); in TEST_F() 100 EXPECT_TRUE(error.IsSuccess()); in TEST_F() 128 std::string error; in TEST_F() local 130 driver_->SendPacket(ip_packet, &error); in TEST_F() 131 EXPECT_EQ(error, "Unexpected call"); in TEST_F() 133 error.clear(); in TEST_F() 135 driver_->SendPacket(ip_packet, &error); in TEST_F() 136 EXPECT_EQ(error, "Device not open"); in TEST_F() 139 error.clear(); in TEST_F() [all …]
|
/system/extras/libpagemap/ |
D | pm_process.c | 36 int error; in pm_process_create() local 48 error = snprintf(filename, MAX_FILENAME, "/proc/%d/pagemap", pid); in pm_process_create() 49 if (error < 0 || error >= MAX_FILENAME) { in pm_process_create() 50 error = (error < 0) ? (errno) : (-1); in pm_process_create() 52 return error; in pm_process_create() 57 error = errno; in pm_process_create() 59 return error; in pm_process_create() 62 error = read_maps(proc); in pm_process_create() 63 if (error) { in pm_process_create() 65 return error; in pm_process_create() [all …]
|
/system/connectivity/shill/dbus/ |
D | chromeos_supplicant_interface_proxy.cc | 149 brillo::ErrorPtr error; in AddNetwork() local 150 if (!interface_proxy_->AddNetwork(dict, &path, &error)) { in AddNetwork() 152 << error->GetCode() << " " << error->GetMessage(); in AddNetwork() 162 brillo::ErrorPtr error; in EnableHighBitrates() local 163 if (!interface_proxy_->EnableHighBitrates(&error)) { in EnableHighBitrates() 165 << error->GetCode() << " " << error->GetMessage(); in EnableHighBitrates() 174 brillo::ErrorPtr error; in EAPLogoff() local 175 if (!interface_proxy_->EAPLogoff(&error)) { in EAPLogoff() 177 << error->GetCode() << " " << error->GetMessage(); in EAPLogoff() 185 brillo::ErrorPtr error; in EAPLogon() local [all …]
|
/system/core/adb/ |
D | adb_client.cpp | 72 static int switch_socket_transport(int fd, std::string* error) { in switch_socket_transport() argument 98 *error = perror_str("write failure during connection"); in switch_socket_transport() 104 if (!adb_status(fd, error)) { in switch_socket_transport() 106 D("Switch transport failed: %s", error->c_str()); in switch_socket_transport() 113 bool adb_status(int fd, std::string* error) { in adb_status() argument 116 *error = perror_str("protocol fault (couldn't read status)"); in adb_status() 125 *error = android::base::StringPrintf("protocol fault (status %02x %02x %02x %02x?!)", in adb_status() 130 ReadProtocolString(fd, error, error); in adb_status() 134 int _adb_connect(const std::string& service, std::string* error) { in _adb_connect() argument 137 *error = android::base::StringPrintf("bad service name length (%zd)", in _adb_connect() [all …]
|
/system/connectivity/shill/cellular/ |
D | cellular_capability.cc | 65 Error* error) { in OnUnsupportedOperation() argument 68 Error::PopulateAndLog(FROM_HERE, error, Error::kNotSupported, message); in OnUnsupportedOperation() 74 Error* error, in Activate() argument 76 OnUnsupportedOperation(__func__, error); in Activate() 79 void CellularCapability::CompleteActivation(Error* error) { in CompleteActivation() argument 80 OnUnsupportedOperation(__func__, error); in CompleteActivation() 89 Error* error, in RegisterOnNetwork() argument 91 OnUnsupportedOperation(__func__, error); in RegisterOnNetwork() 96 Error* error, in RequirePIN() argument 98 OnUnsupportedOperation(__func__, error); in RequirePIN() [all …]
|
D | cellular_capability_gsm.cc | 125 KeyValueStore(CellularCapabilityGSM::*get)(Error* error)) { in HelpRegisterConstDerivedKeyValueStore() argument 169 void CellularCapabilityGSM::StartModem(Error* error, in StartModem() argument 299 Error* error, in Connect() argument 305 simple_proxy_->Connect(properties, error, cb, kTimeoutConnect); in Connect() 309 const Error& error) { in OnConnectReply() argument 315 } else if (error.IsFailure()) { in OnConnectReply() 321 if (error.type() == Error::kInvalidApn && !apn_try_list_.empty()) { in OnConnectReply() 327 Error error; in OnConnectReply() local 328 Connect(props, &error, callback); in OnConnectReply() 336 callback.Run(error); in OnConnectReply() [all …]
|
/system/keymaster/ |
D | aes_operation.cpp | 80 keymaster_error_t* error) { in CreateOperation() argument 81 *error = KM_ERROR_OK; in CreateOperation() 90 *error = KM_ERROR_UNSUPPORTED_KEY_SIZE; in CreateOperation() 97 *error = KM_ERROR_UNSUPPORTED_BLOCK_MODE; in CreateOperation() 101 *error = KM_ERROR_UNSUPPORTED_BLOCK_MODE; in CreateOperation() 105 *error = KM_ERROR_INCOMPATIBLE_BLOCK_MODE; in CreateOperation() 111 *error = GetAndValidateGcmTagLength(begin_params, key.authorizations(), &tag_length); in CreateOperation() 112 if (*error != KM_ERROR_OK) { in CreateOperation() 118 if (!GetAndValidatePadding(begin_params, key, &padding, error)) { in CreateOperation() 123 *error = KM_ERROR_INCOMPATIBLE_PADDING_MODE; in CreateOperation() [all …]
|
D | android_keymaster.cpp | 88 response->error = KM_ERROR_UNSUPPORTED_ALGORITHM; in check_supported() 101 rsp->error = KM_ERROR_OK; in GetVersion() 109 response->error = KM_ERROR_OK; in SupportedAlgorithms() 118 response->error = KM_ERROR_MEMORY_ALLOCATION_FAILED; in SupportedAlgorithms() 131 response->error = KM_ERROR_UNSUPPORTED_PURPOSE; in GetSupported() 182 response->error = context_->AddRngEntropy(request.random_data.peek_read(), in AddRngEntropy() 196 response->error = KM_ERROR_UNSUPPORTED_ALGORITHM; in GenerateKey() 201 response->error = factory->GenerateKey(request.key_description, &key_blob, in GenerateKey() 203 if (response->error == KM_ERROR_OK) in GenerateKey() 214 response->error = in GetKeyCharacteristics() [all …]
|
D | rsa_operation.cpp | 40 EVP_PKEY* RsaOperationFactory::GetRsaKey(const Key& key, keymaster_error_t* error) { in GetRsaKey() argument 44 *error = KM_ERROR_UNKNOWN_ERROR; in GetRsaKey() 50 *error = KM_ERROR_UNKNOWN_ERROR; in GetRsaKey() 67 keymaster_error_t* error) { in CreateRsaOperation() argument 69 if (!GetAndValidatePadding(begin_params, key, &padding, error)) in CreateRsaOperation() 76 if (require_digest && !GetAndValidateDigest(begin_params, key, &digest, error)) in CreateRsaOperation() 79 UniquePtr<EVP_PKEY, EVP_PKEY_Delete> rsa(GetRsaKey(key, error)); in CreateRsaOperation() 85 *error = KM_ERROR_MEMORY_ALLOCATION_FAILED; in CreateRsaOperation() 99 keymaster_error_t* error) { in CreateRsaOperation() argument 100 UniquePtr<RsaOperation> op(RsaOperationFactory::CreateRsaOperation(key, begin_params, error)); in CreateRsaOperation() [all …]
|
/system/core/base/ |
D | parsenetaddress_test.cpp | 24 std::string canonical, host, error; in TEST() local 28 ParseNetAddress("www.google.com", &host, &port, &canonical, &error)); in TEST() 34 ParseNetAddress("www.google.com:666", &host, &port, &canonical, &error)); in TEST() 41 std::string canonical, host, error; in TEST() local 44 EXPECT_TRUE(ParseNetAddress("1.2.3.4", &host, &port, &canonical, &error)); in TEST() 49 EXPECT_TRUE(ParseNetAddress("1.2.3.4:666", &host, &port, &canonical, &error)); in TEST() 56 std::string canonical, host, error; in TEST() local 59 EXPECT_TRUE(ParseNetAddress("::1", &host, &port, &canonical, &error)); in TEST() 65 &canonical, &error)); in TEST() 70 EXPECT_TRUE(ParseNetAddress("[::1]:666", &host, &port, &canonical, &error)); in TEST() [all …]
|
/system/connectivity/shill/wifi/ |
D | tdls_manager_unittest.cc | 85 Error error; in TEST_F() local 97 kPeer, kTDLSDiscoverOperation, &error)); in TEST_F() 98 EXPECT_TRUE(error.IsSuccess()); in TEST_F() 105 error.Reset(); in TEST_F() 111 kPeer, kTDLSDiscoverOperation, &error)); in TEST_F() 112 EXPECT_EQ(Error::kOperationFailed, error.type()); in TEST_F() 119 Error error; in TEST_F() local 126 kPeer, kTDLSSetupOperation, &error)); in TEST_F() 127 EXPECT_TRUE(error.IsSuccess()); in TEST_F() 131 error.Reset(); in TEST_F() [all …]
|
/system/webservd/webservd/ |
D | config_unittest.cc | 167 brillo::ErrorPtr error; in TEST() local 169 ASSERT_FALSE(LoadConfigFromString(kInvalidConfig_NotDict, &config, &error)); in TEST() 170 EXPECT_EQ(brillo::errors::json::kDomain, error->GetDomain()); in TEST() 171 EXPECT_EQ(brillo::errors::json::kObjectExpected, error->GetCode()); in TEST() 173 error->GetMessage()); in TEST() 177 brillo::ErrorPtr error; in TEST() local 179 ASSERT_FALSE(LoadConfigFromString(kInvalidConfig_NoName, &config, &error)); in TEST() 180 EXPECT_EQ(webservd::errors::kDomain, error->GetDomain()); in TEST() 181 EXPECT_EQ(webservd::errors::kInvalidConfig, error->GetCode()); in TEST() 183 error->GetMessage()); in TEST() [all …]
|
/system/core/fastboot/ |
D | udp.cpp | 106 std::string* error); 117 bool InitializeProtocol(std::string* error); 125 size_t rx_length, int attempts, std::string* error); 131 std::string* error); 142 std::string* error) { in NewTransport() argument 145 if (!transport->InitializeProtocol(error)) { in NewTransport() 152 bool UdpTransport::InitializeProtocol(std::string* error) { in InitializeProtocol() argument 161 kMaxConnectAttempts, error); in InitializeProtocol() 165 *error = "invalid query response from target"; in InitializeProtocol() 175 kMaxTransmissionAttempts, error); in InitializeProtocol() [all …]
|
/system/connectivity/apmanager/dbus/ |
D | shill_dbus_proxy.cc | 62 brillo::ErrorPtr error; in ClaimInterface() local 63 if (!manager_proxy_->ClaimInterface(kServiceName, interface_name, &error)) { in ClaimInterface() 65 << error->GetCode() << " " << error->GetMessage(); in ClaimInterface() 76 brillo::ErrorPtr error; in ReleaseInterface() local 77 if (!manager_proxy_->ReleaseInterface(kServiceName, interface_name, &error)) { in ReleaseInterface() 79 << error->GetCode() << " " << error->GetMessage(); in ReleaseInterface() 91 brillo::ErrorPtr error; in SetupApModeInterface() local 92 if (!manager_proxy_->SetupApModeInterface(interface_name, &error)) { in SetupApModeInterface() 94 << error->GetCode() << " " << error->GetMessage(); in SetupApModeInterface() 105 brillo::ErrorPtr error; in SetupStationModeInterface() local [all …]
|