mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-22 09:17:58 +00:00
hv:Fix unused var value on all paths
MISRAC checks whether a variable is assigned a value not used in all branches of a program. Var value which is unused on all paths can be removed with a consequent improvement in the readability and efficiency of the code. This patch is used to fix these violations. Tracked-On: #861 Signed-off-by: Junjun Shan <junjun.shan@intel.com> Acked-by: Anthony Xu <anthony.xu@intel.com>
This commit is contained in:
@@ -657,7 +657,7 @@ int vsnprintf(char *dst_arg, size_t sz_arg, const char *fmt, va_list args)
|
||||
{
|
||||
char *dst = dst_arg;
|
||||
uint32_t sz = sz_arg;
|
||||
int res = 0;
|
||||
int res;
|
||||
|
||||
if ((sz == 0U) || (dst == NULL)) {
|
||||
return -1;
|
||||
|
Reference in New Issue
Block a user