Skip to contentSkip to conversation

create_proc_entry return code audit

KJ Amol Lad 1 participant 1 message Sep 13, 2006 Kernel janitors

lore
Share & tools
lore

Amol Lad

author
#0 lore raw

Hi,

I'm working on handling error return code for create_proc_entry. Currently there are three ways the function is called
1. call create_proc_entry as a 'void' function
2. call create_proc_entry and directly use the return value without checking if it's non-NULL
3. call create_proc_entry and check for non-NULL but do not throw any warning message that create_proc_entry failed.

Method 3 is widely used followed by 1 and we have some cases for 2 also.

what do you folks suggest, we fix all three or only 1 & 2. I feel we should fix 3 also and add a KERN_WARNING message for the same

Thanks

_______________________________________________
Kernel-janitors mailing list
[email protected]
https://lists.osdl.org/mailman/listinfo/kernel-janitors