Message ID | 20240412082351.930802-1-arkadiusz.bokowy@gmail.com (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | [BlueZ,v2] advertising: Do not crash in case of adv update failure | expand |
Context | Check | Description |
---|---|---|
tedd_an/pre-ci_am | success | Success |
tedd_an/CheckPatch | success | CheckPatch PASS |
tedd_an/GitLint | success | Gitlint PASS |
tedd_an/BuildEll | success | Build ELL PASS |
tedd_an/BluezMake | success | Bluez Make PASS |
tedd_an/MakeCheck | success | Bluez Make Check PASS |
tedd_an/MakeDistcheck | success | Make Distcheck PASS |
tedd_an/CheckValgrind | success | Check Valgrind PASS |
tedd_an/CheckSmatch | success | CheckSparse PASS |
tedd_an/bluezmakeextell | success | Make External ELL PASS |
tedd_an/IncrementalBuild | success | Incremental Build PASS |
tedd_an/ScanBuild | success | Scan Build PASS |
This is automated email and please do not reply to this email! Dear submitter, Thank you for submitting the patches to the linux bluetooth mailing list. This is a CI test results with your patch series: PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=843919 ---Test result--- Test Summary: CheckPatch PASS 0.31 seconds GitLint PASS 0.22 seconds BuildEll PASS 24.27 seconds BluezMake PASS 1679.26 seconds MakeCheck PASS 12.80 seconds MakeDistcheck PASS 179.41 seconds CheckValgrind PASS 248.75 seconds CheckSmatch PASS 349.07 seconds bluezmakeextell PASS 118.00 seconds IncrementalBuild PASS 1422.69 seconds ScanBuild PASS 1037.22 seconds --- Regards, Linux Bluetooth
diff --git a/src/advertising.c b/src/advertising.c index 7f55a20e3..ad28f6f77 100644 --- a/src/advertising.c +++ b/src/advertising.c @@ -1259,9 +1259,18 @@ static void add_client_complete(struct btd_adv_client *client, uint8_t status) { DBusMessage *reply; - if (status) { + if (status) error("Failed to add advertisement: %s (0x%02x)", mgmt_errstr(status), status); + + /* If the advertising request was not started by a direct call from + * the client, but rather by a refresh due to properties update or + * our internal timer, there is nothing to reply to. + */ + if (client->reg == NULL) + return; + + if (status) { reply = btd_error_failed(client->reg, "Failed to register advertisement"); queue_remove(client->manager->clients, client);