Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-5493

New static analysis issues in 2.6.50-112-g01def2b

Details

    • Bug
    • Resolution: Fixed
    • Minor
    • Lustre 2.7.0
    • None
    • 3
    • 15333

    Description

      Found 2 new static analysis issues in 2.6.50-112-g01def2b:

      1. Result of function that can return NULL may be dereferenced
        • lnet/lnet/api-ni.c: in LNetNIInit, Pointer 'nets' returned from call to function 'lnet_get_networks' at line 1779 may be NULL and may be dereferenced at line 1785.
          TRACEBACK
          api-ni.c:1779: 'nets' is assigned the return value from function 'lnet_get_networks'.
          api-ni.c:85: 'lnet_get_networks' explicitly returns a NULL value.
          api-ni.c:1785: 'nets' is dereferenced by passing argument 2 to function 'lnet_parse_networks'.
          config.c:197: 'networks' is passed to function 'lnet_parse_networks'.
          config.c:200: 'networks' is dereferenced by passing argument 1 to function 'strlen'.
      1. Joining with binary operator does not respect strong typing
        • lnet/lnet/api-ni.c: in lnet_ping_info_install_locked, A strongly typed value of type '__u32' is compared with a value of a different type 'int'

      The list of commits since the previous build 2.6.50-106-g9593c98:

      01def2b LU-2675 build: remove Darwin "support"
      92c5184 LU-2456 lnet: DLC Feature dynamic net config
      18ad797 LU-5418 libcfs: only define noop_*_fn when readline is used
      c079e8c LU-2456 lnet: Dynamic LNet Configuration (DLC) dynamic routing
      d018343 LU-5476 llite: Fix integer overflow in ll_fid2path
      94d923d LU-4423 obdecho: bitwise vs logical typo

      Attachments

        Issue Links

          Activity

            [LU-5493] New static analysis issues in 2.6.50-112-g01def2b
            adilger Andreas Dilger made changes -
            Link New: This issue is related to LU-4629 [ LU-4629 ]
            dmiter Dmitry Eremin (Inactive) made changes -
            Link New: This issue is related to LU-5540 [ LU-5540 ]
            dmiter Dmitry Eremin (Inactive) made changes -
            Fix Version/s New: Lustre 2.7.0 [ 10631 ]
            Resolution New: Fixed [ 1 ]
            Status Original: Open [ 1 ] New: Resolved [ 5 ]
            dmiter Dmitry Eremin (Inactive) added a comment - - edited Fixed by http://review.whamcloud.com/#/c/11626/5
            dmiter Dmitry Eremin (Inactive) made changes -
            Description Original: Found 2 new static analysis issues in 2.6.50-112-g01def2b:
            # *Result of function that can return NULL may be dereferenced*
            #* {{lnet/lnet/api-ni.c}}: in _LNetNIInit_, Pointer 'nets' returned from call to function 'lnet\_get\_networks' at line 1779 may be NULL and may be dereferenced at line 1785.
            # *Joining with binary operator does not respect strong typing*
            #* {{lnet/lnet/api-ni.c}}: in _lnet_ping_info_install_locked_, A strongly typed value of type '\_\_u32' is compared with a value of a different type 'int'

            The list of commits since the previous build 2.6.50-106-g9593c98:
            |[01def2b|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=01def2b635ff0b7bacde158d9124334c42cd5d2b]|LU-2675 build: remove Darwin "support"|
            |[92c5184|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=92c51841c50cc4061c20b277d3f7c4468f2a80cc]|LU-2456 lnet: DLC Feature dynamic net config|
            |[18ad797|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=18ad797d5da11a8ce886c8d0cce9b1e043c4c898]|LU-5418 libcfs: only define noop_*_fn when readline is used|
            |[c079e8c|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=c079e8c57a09419b1e5978dba2a469d6ae4c712c]|LU-2456 lnet: Dynamic LNet Configuration (DLC) dynamic routing|
            |[d018343|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=d01834323af7a14d2d4959d9bea58073e3bb16ea]|LU-5476 llite: Fix integer overflow in ll_fid2path|
            |[94d923d|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=94d923de400fc1c6a50b67a55ce700251f93ab05]|LU-4423 obdecho: bitwise vs logical typo|
            New: Found 2 new static analysis issues in 2.6.50-112-g01def2b:
            # *Result of function that can return NULL may be dereferenced*
            #* {{lnet/lnet/api-ni.c}}: in _LNetNIInit_, Pointer 'nets' returned from call to function 'lnet\_get\_networks' at line 1779 may be NULL and may be dereferenced at line 1785.
            TRACEBACK
            api-ni.c:1779: 'nets' is assigned the return value from function 'lnet_get_networks'.
            api-ni.c:85: 'lnet_get_networks' explicitly returns a NULL value.
            api-ni.c:1785: 'nets' is dereferenced by passing argument 2 to function 'lnet_parse_networks'.
            config.c:197: 'networks' is passed to function 'lnet_parse_networks'.
            config.c:200: 'networks' is dereferenced by passing argument 1 to function 'strlen'.

            # *Joining with binary operator does not respect strong typing*
            #* {{lnet/lnet/api-ni.c}}: in _lnet_ping_info_install_locked_, A strongly typed value of type '\_\_u32' is compared with a value of a different type 'int'

            The list of commits since the previous build 2.6.50-106-g9593c98:
            |[01def2b|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=01def2b635ff0b7bacde158d9124334c42cd5d2b]|LU-2675 build: remove Darwin "support"|
            |[92c5184|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=92c51841c50cc4061c20b277d3f7c4468f2a80cc]|LU-2456 lnet: DLC Feature dynamic net config|
            |[18ad797|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=18ad797d5da11a8ce886c8d0cce9b1e043c4c898]|LU-5418 libcfs: only define noop_*_fn when readline is used|
            |[c079e8c|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=c079e8c57a09419b1e5978dba2a469d6ae4c712c]|LU-2456 lnet: Dynamic LNet Configuration (DLC) dynamic routing|
            |[d018343|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=d01834323af7a14d2d4959d9bea58073e3bb16ea]|LU-5476 llite: Fix integer overflow in ll_fid2path|
            |[94d923d|http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=94d923de400fc1c6a50b67a55ce700251f93ab05]|LU-4423 obdecho: bitwise vs logical typo|
            dmiter Dmitry Eremin (Inactive) created issue -

            People

              wc-triage WC Triage
              dmiter Dmitry Eremin (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: