Search Linux Wireless

Re: [PATCH] mwifiex: remove duplicated NULL checks

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

 



On Sat, Jan 15, 2011 at 06:36, Bing Zhao <bzhao@xxxxxxxxxxx> wrote:
> From: Amitkumar Karwar <akarwar@xxxxxxxxxxx>
>
> Some functions have unnecessory NULL check for an input parameter
> because the caller to those functions is already checking the parameter
> for NULL before calling them.

It may be more readable and efficient to eliminate the NULL checks in
the callers - and adjust the code to inform the callers of the case
where the pointer passed is null and make the callers to properly
handle this case.

This should also make the driver more robust as failures can be passed
up the stack to places that can deal with them more effectively than
just printing a message.

Thanks,

-- 

Julian Calaby

Email: julian.calaby@xxxxxxxxx
Profile: http://www.google.com/profiles/julian.calaby/
.Plan: http://sites.google.com/site/juliancalaby/
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux