Project

General

Profile

Bug #8461

fcip: 'tok_buf_size' may be used uninitialized in this function

Added by Toomas Soome over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
driver - device drivers
Start date:
2017-07-05
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
Gerrit CR:

Description

Build issue from gcc 6:

../../common/io/fibre-channel/ulp/fcip.c: In function 'fcip_init_port':
../../common/io/fibre-channel/ulp/fcip.c:4860:3: error: 'tok_buf_size' may be used uninitialized in this function [-Werror=maybe-uninitialized]
   kmem_free(tokens, tok_buf_size);
   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors

It really "feels" like false positive, but it does not hurt to set the tok_bubf_size to 0 anyhow.

#1

Updated by Electric Monk over 3 years ago

  • Status changed from In Progress to Closed
  • % Done changed from 90 to 100

git commit af9e810c3c08e96f9273e4caa6732b245a676b1b

commit  af9e810c3c08e96f9273e4caa6732b245a676b1b
Author: Toomas Soome <tsoome@me.com>
Date:   2017-08-02T17:07:40.000Z

    8461 fcip: 'tok_buf_size' may be used uninitialized in this function
    Reviewed by: Peter Tribble <peter.tribble@gmail.com>
    Reviewed by: Jason King <jason.brian.king@gmail.com>
    Reviewed by: Gary Mills <gary_mills@fastmail.fm>
    Approved by: Richard Lowe <richlowe@richlowe.net>

Also available in: Atom PDF