re: Squashfs: Refactor decompressor interface and code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Phillip Lougher,

The patch ac379b0dec4b: "Squashfs: Refactor decompressor interface
and code" from Oct 7, 2013, leads to the following
static checker warning: "fs/squashfs/decompressor.c:138
squashfs_decompressor_setup()
	 warn: 'comp_opts' was already freed."

fs/squashfs/decompressor.c
   128  void *squashfs_decompressor_setup(struct super_block *sb, unsigned short flags)
   129  {
   130          struct squashfs_sb_info *msblk = sb->s_fs_info;
   131          void *stream, *comp_opts = get_comp_opts(sb, flags);
   132  
   133          if (IS_ERR(comp_opts))
   134                  return comp_opts;
   135  
   136          stream = squashfs_decompressor_create(msblk, comp_opts);
   137          if (IS_ERR(stream))
   138                  kfree(comp_opts);

The _single version of squashfs_decompressor_create() frees comp_opts
but the _multi version doesn't.  I'm not sure what the right thing to do
is here.

   139  
   140          return stream;
   141  }

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux