Bug 224196 - Missing opening curly brace in zfsboot.c
Summary: Missing opening curly brace in zfsboot.c
Status: Closed Not A Bug
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: i386 Any
: --- Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-12-09 06:30 UTC by Darin Luckie
Modified: 2017-12-09 10:06 UTC (History)
1 user (show)

See Also:


Attachments
Code in head is missing curly brace (30.01 KB, image/png)
2017-12-09 06:34 UTC, Darin Luckie
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Darin Luckie 2017-12-09 06:30:42 UTC
/usr/src/stand/i386/zfsboot/zfsboot.c

		if (!OPT_CHECK(RBX_QUIET)) {
		    printf("zfs nextboot: %s\n", cmddup);
	    }

should be

		if (!OPT_CHECK(RBX_QUIET)) {
		    printf("zfs nextboot: %s\n", cmddup);
	    }
Comment 1 Darin Luckie 2017-12-09 06:34:56 UTC
Created attachment 188641 [details]
Code in head is missing curly brace
Comment 2 Kristof Provost freebsd_committer freebsd_triage 2017-12-09 10:06:12 UTC
The code is correct. It's permissible to not have curly braces around single-line blocks, which is the case here. There are several more examples of this in the same file.

I suspect you were confused by the admittedly poor indentation style of this code. It mixes spaces and tabs, which can look very confusing with some editor configurations.