linux-bluetooth.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH BlueZ] adapter: Fix generating IRK for adapter with privacy enabled
@ 2023-07-28  4:45 Simon Mikuda
  2023-07-28  6:26 ` [BlueZ] " bluez.test.bot
  2023-07-28 22:50 ` [PATCH BlueZ] " patchwork-bot+bluetooth
  0 siblings, 2 replies; 3+ messages in thread
From: Simon Mikuda @ 2023-07-28  4:45 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Simon Mikuda

When root folder for adapter doesn't exist we will get this runtime error:
src/adapter.c:generate_and_write_irk() Unable set contents for /var/lib/bluetooth/00:00:00:00:00:00/identity: (Failed to create file “/var/lib/bluetooth/00:00:00:00:00:00/identity.EKQ581”: No such file or directory)
---
 src/adapter.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/adapter.c b/src/adapter.c
index 2679d4302..fda26fb93 100644
--- a/src/adapter.c
+++ b/src/adapter.c
@@ -4148,6 +4148,7 @@ static int generate_and_write_irk(uint8_t *irk, GKeyFile *key_file,
 
 	g_key_file_set_string(key_file, "General", "IdentityResolvingKey",
 								str_irk_out);
+	create_file(filename, S_IRUSR | S_IWUSR);
 	str = g_key_file_to_data(key_file, &length, NULL);
 	if (!g_file_set_contents(filename, str, length, &gerr)) {
 		error("Unable set contents for %s: (%s)", filename,
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* RE: [BlueZ] adapter: Fix generating IRK for adapter with privacy enabled
  2023-07-28  4:45 [PATCH BlueZ] adapter: Fix generating IRK for adapter with privacy enabled Simon Mikuda
@ 2023-07-28  6:26 ` bluez.test.bot
  2023-07-28 22:50 ` [PATCH BlueZ] " patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: bluez.test.bot @ 2023-07-28  6:26 UTC (permalink / raw)
  To: linux-bluetooth, simon.mikuda

[-- Attachment #1: Type: text/plain, Size: 2692 bytes --]

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=770390

---Test result---

Test Summary:
CheckPatch                    FAIL      0.67 seconds
GitLint                       FAIL      0.54 seconds
BuildEll                      PASS      34.98 seconds
BluezMake                     PASS      1061.37 seconds
MakeCheck                     PASS      13.91 seconds
MakeDistcheck                 PASS      198.62 seconds
CheckValgrind                 PASS      320.73 seconds
CheckSmatch                   PASS      423.57 seconds
bluezmakeextell               PASS      132.24 seconds
IncrementalBuild              PASS      860.86 seconds
ScanBuild                     PASS      1368.01 seconds

Details
##############################
Test: CheckPatch - FAIL
Desc: Run checkpatch.pl script
Output:
[BlueZ] adapter: Fix generating IRK for adapter with privacy enabled
WARNING:SYMBOLIC_PERMS: Symbolic permissions 'S_IRUSR | S_IWUSR' are not preferred. Consider using octal permissions '0600'.
#91: FILE: src/adapter.c:4151:
+	create_file(filename, S_IRUSR | S_IWUSR);

/github/workspace/src/src/13331180.patch total: 0 errors, 1 warnings, 7 lines checked

NOTE: For some of the reported defects, checkpatch may be able to
      mechanically convert to the typical style using --fix or --fix-inplace.

/github/workspace/src/src/13331180.patch has style problems, please review.

NOTE: Ignored message types: COMMIT_MESSAGE COMPLEX_MACRO CONST_STRUCT FILE_PATH_CHANGES MISSING_SIGN_OFF PREFER_PACKED SPDX_LICENSE_TAG SPLIT_STRING SSCANF_TO_KSTRTO

NOTE: If any of the errors are false positives, please report
      them to the maintainer, see CHECKPATCH in MAINTAINERS.


##############################
Test: GitLint - FAIL
Desc: Run gitlint
Output:
[BlueZ] adapter: Fix generating IRK for adapter with privacy enabled

WARNING: I3 - ignore-body-lines: gitlint will be switching from using Python regex 'match' (match beginning) to 'search' (match anywhere) semantics. Please review your ignore-body-lines.regex option accordingly. To remove this warning, set general.regex-style-search=True. More details: https://jorisroovers.github.io/gitlint/configuration/#regex-style-search
4: B1 Line exceeds max length (215>80): "src/adapter.c:generate_and_write_irk() Unable set contents for /var/lib/bluetooth/00:00:00:00:00:00/identity: (Failed to create file “/var/lib/bluetooth/00:00:00:00:00:00/identity.EKQ581”: No such file or directory)"


---
Regards,
Linux Bluetooth


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH BlueZ] adapter: Fix generating IRK for adapter with privacy enabled
  2023-07-28  4:45 [PATCH BlueZ] adapter: Fix generating IRK for adapter with privacy enabled Simon Mikuda
  2023-07-28  6:26 ` [BlueZ] " bluez.test.bot
@ 2023-07-28 22:50 ` patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+bluetooth @ 2023-07-28 22:50 UTC (permalink / raw)
  To: Simon Mikuda; +Cc: linux-bluetooth

Hello:

This patch was applied to bluetooth/bluez.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:

On Fri, 28 Jul 2023 06:45:56 +0200 you wrote:
> When root folder for adapter doesn't exist we will get this runtime error:
> src/adapter.c:generate_and_write_irk() Unable set contents for /var/lib/bluetooth/00:00:00:00:00:00/identity: (Failed to create file “/var/lib/bluetooth/00:00:00:00:00:00/identity.EKQ581”: No such file or directory)
> ---
>  src/adapter.c | 1 +
>  1 file changed, 1 insertion(+)

Here is the summary with links:
  - [BlueZ] adapter: Fix generating IRK for adapter with privacy enabled
    https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=16c1166d8737

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-07-28 22:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-28  4:45 [PATCH BlueZ] adapter: Fix generating IRK for adapter with privacy enabled Simon Mikuda
2023-07-28  6:26 ` [BlueZ] " bluez.test.bot
2023-07-28 22:50 ` [PATCH BlueZ] " patchwork-bot+bluetooth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).