Skip to main content
ALT Linux Bugzilla
– Attachment 22327 Details for
Bug 60776
libnss-role: D-Bus падает при раннем старте, если Winbind ещё недоступен
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
libnss-role-winbind-enoent.patch
libnss-role-winbind-enoent.patch (text/plain), 1.25 KB, created by
Vladislav Glinkin
on 2026-10-01 15:58:44 MSK
(
hide
)
Description:
libnss-role-winbind-enoent.patch
Filename:
MIME Type:
Creator:
Vladislav Glinkin
Created:
2026-10-01 15:58:44 MSK
Size:
1.25 KB
patch
obsolete
>From: ALT Linux investigation >Subject: [PATCH] Treat unavailable NSS groups as absent and avoid freeing graph data > >When getgrnam_r() reaches an unavailable NSS provider such as winbind, glibc >may return ENOENT. Role members are optional, so treat this like a missing >group. Also, parse_line() can be extending an existing graph node; its error >path must not free the node's list, which remains owned by the graph. > >This patch is prepared against libnss-role source revision d40c8cd >(0.5.6-alt4 source used by the test VM). > >--- a/src/common.c >+++ b/src/common.c >@@ -193,8 +193,11 @@ static int get_gid_by_groupname(const char *gr_name, gid_t *gid) > } > > if (err != 0) { > free(buffer); >+ /* An NSS provider may report an unavailable database as ENOENT. */ >+ if (err == ENOENT) >+ return LIBROLE_NO_SUCH_GROUP; > return errno_to_result(err); > } > if (!grp_ptr) { > free(buffer); >--- a/src/parser.c >+++ b/src/parser.c >@@ -297,6 +297,8 @@ int parse_line(char *line, struct librole_graph *G) > return result; > > libnss_role_parse_line_error: >- free(role->list); >+ /* Existing role lists are owned by G and freed by librole_graph_free(). */ >+ if (!role_exists) >+ free(role->list); > return result; > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 60776
:
22326
| 22327