4 ms·
Is it you or openssh that declares two variables on one line (int result, ok)? I hope it's just you, because that's bad practice :-/
by mahmud 13y ago
Is it you or openssh that declares two variables on one line (int result, ok)? I hope it's just you, because that's bad practice :-/
- jrockway 13y agoFor someone here criticizing C style, I'm surprised you can't read unified diffs. The lines starting with " " are context. The lines starting with "+" are the ones the author of the patch added.
- mahmud 13y agoThat's what I get for reading diffs on a mobile phone at 11PM. But my concern does stand, OpenSSH does allow for multiple declarations on one line in their style guide.
- brohee 13y agoOpenSSH is in Kernel Normal Form (http://www.openbsd.org/cgi-bin/man.cgi?query=style§ion=9 http://www.openbsd.org/cgi-bin/man.cgi?query=style§ion=9) which doesn't have any qualms about it. Specifically it says : "When declaring variables in functions, declare them sorted by size (largest to smallest), then in alphabetical order; multiple ones per line are okay."
- mahmud 13y agoRiiight. Thank you. That answers my question.