Module Name: src Committed By: simonb Date: Mon Oct 31 09:14:18 UTC 2022
Modified Files: src/sys/kern: subr_prf.c Log Message: Fix (invalid) gcc uninitialised warning with i386 gcc using -Os. To generate a diff of this commit: cvs rdiff -u -r1.195 -r1.196 src/sys/kern/subr_prf.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/kern/subr_prf.c diff -u src/sys/kern/subr_prf.c:1.195 src/sys/kern/subr_prf.c:1.196 --- src/sys/kern/subr_prf.c:1.195 Wed Oct 26 23:28:42 2022 +++ src/sys/kern/subr_prf.c Mon Oct 31 09:14:18 2022 @@ -1,4 +1,4 @@ -/* $NetBSD: subr_prf.c,v 1.195 2022/10/26 23:28:42 riastradh Exp $ */ +/* $NetBSD: subr_prf.c,v 1.196 2022/10/31 09:14:18 simonb Exp $ */ /*- * Copyright (c) 1986, 1988, 1991, 1993 @@ -37,7 +37,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: subr_prf.c,v 1.195 2022/10/26 23:28:42 riastradh Exp $"); +__KERNEL_RCSID(0, "$NetBSD: subr_prf.c,v 1.196 2022/10/31 09:14:18 simonb Exp $"); #ifdef _KERNEL_OPT #include "opt_ddb.h" @@ -402,6 +402,8 @@ putone(int c, int flags, struct tty *tp) struct tty *ctp; int s; + ctp = NULL; /* XXX gcc i386 -Os */ + /* * Ensure whatever constty points to can't go away while we're * trying to use it.