Re: [PATCH v2 20/21] config.c: handle error on failing to fopen()

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

 



Hi Duy,

On Wed, 3 May 2017, Nguyễn Thái Ngọc Duy wrote:

> In the first case, we already correctly return -1 if fopen() fails to
> open. But we should report something so people know what's wrong.
> 
> In the second case, config_file == NULL does not necessarily mean "no
> config file". Bail out if needed.
> 
> Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@xxxxxxxxx>

Again, it seems that your patch series tries to cut at the file boundary,
not at the "logically the same change" boundary, making it a bit more
cumbersome than necessary to follow this patch series.

I highly recommend squashing the first change into the big fopen() ->
fopen_or_warn() patch I hinted at earlier, and let the second change (with
the accompanying test case) stand on its own.

Ciao,
Dscho

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]