]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Silence newer gcc warnings.
authorRick Macklem <rmacklem@FreeBSD.org>
Thu, 2 Aug 2018 20:10:59 +0000 (20:10 +0000)
committerRick Macklem <rmacklem@FreeBSD.org>
Thu, 2 Aug 2018 20:10:59 +0000 (20:10 +0000)
commitac0d64958897d94e333dd5b2bc4edc55ce30fe59
treedffa9cc61f4a8457f0aa2ec1537aa373d115b600
parentaba9f1124f6ffc106bd7ef0086b9439d80ff9769
Silence newer gcc warnings.

Newer versions of gcc generate "might not be initialized" warnings for
several variables in nfsrpc_doiods().  I have checked and all of these
variables are assigned values before they are used.
In the one case of "tdrpc", it could have passed garbage as an argument
to nfscl_dofflayoutio() when mirrorcnt is one. However nfscl_dofflayoutio() only
uses the argument when mirrorcnt > 1, so it wasn't actually broken.
This patch initializes "tdrpc" to avoid confusion and initializes the rest
to make the compiler happy.

Requested by: mmacy
sys/fs/nfsclient/nfs_clrpcops.c