[Bug 274875] A possible null-pointer dereference caused by a data race in sys/geom/gate/g_gate.c
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 274875] A possible null-pointer dereference caused by a data race in sys/geom/gate/g_gate.c"
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 274875] A possible null-pointer dereference caused by a data race in sys/geom/gate/g_gate.c"
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 274875] A possible null-pointer dereference caused by a data race in sys/geom/gate/g_gate.c"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 02 Nov 2023 16:48:15 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=274875 Bug ID: 274875 Summary: A possible null-pointer dereference caused by a data race in sys/geom/gate/g_gate.c Product: Base System Version: 14.0-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: islituo@gmail.com In the function g_gate_dumpconf(), sc->sc_readcons is first checked to be not NULL: if (sc->sc_readcons != NULL) and then dereferenced: sbuf_printf(sb, "%s<read_provider>%s</read_provider>\n", indent, sc->sc_readcons->provider->name); However, sc->sc_readcons can be set to NULL by other functions such as g_gate_modify() right after it is checked: sc->sc_readcons = NULL; and thus can cause a null-pointer dereference. -- You are receiving this mail because: You are the assignee for the bug.