Skip to content

Fix Windows (crlf) related compilation error #167

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed

Fix Windows (crlf) related compilation error #167

wants to merge 2 commits into from

Conversation

ThomDietrich
Copy link

Closes #144

The issue stays unclear to me. This "style fix" solved it.

Closes #144

The issue stays unclear to me. This "style fix" solved it.
@arendst
Copy link
Owner

arendst commented Mar 8, 2017

I guess changing it from this:

void sl_blank(byte state)
/*
 * Called by interrupt disabling routines like OTA or web upload
 * state = 0: No blank
 *         1: Blank led to solve flicker
 */
{
  if (sysCfg.module == SONOFF_LED) {

to this

void sl_blank(byte state)
{
/*
 * Called by interrupt disabling routines like OTA or web upload
 * state = 0: No blank
 *         1: Blank led to solve flicker
 */
  if (sysCfg.module == SONOFF_LED) {

would also solve the problem as I guess the culprit is the space between the function definition and the {

@ThomDietrich
Copy link
Author

Did you see my explanation over in the issue?

Yes moving the { above the comment also solves the issue. No the space is not to blame. You can have as many spaces as you like in your code. As I stated in the issue, the problem only occurs with a four+ line block comment. Very strange.

The PR follows common style standards but you can also go with the other solution, that's of course up to you ;) You have write access to this PR.

@arendst
Copy link
Owner

arendst commented Mar 8, 2017

Already changed to this one in next release ;-)

void sl_blank(byte state)
{
// Called by interrupt disabling routines like OTA or web upload
// state = 0: No blank
//         1: Blank led to solve flicker

@ThomDietrich
Copy link
Author

ThomDietrich commented Mar 8, 2017

No love for PRs?

@ThomDietrich ThomDietrich deleted the patch-1 branch March 8, 2017 12:21
arendst added a commit that referenced this pull request Mar 8, 2017
4.0.2 20170308
* Restore correct seriallog level after Serial logging was disabled
* Add simple dimmer slider to Sonoff Led web page
* Reduced root webpage size by 31%
* Expand Status 2 with Build date/time and core version
* Fix webserver redirection when not in WifiManager mode (#156)
* Add command ButtonRestrict On/Off to restrict access to button hold
and button multi press options above 2 (#161)
* Fix DS18S20 negative temperature readings (#165)
* Fix crlf compilation error due to bad syntax (#144, #167)
curzon01 pushed a commit to curzon01/Tasmota that referenced this pull request Sep 6, 2018
4.0.2 20170308
* Restore correct seriallog level after Serial logging was disabled
* Add simple dimmer slider to Sonoff Led web page
* Reduced root webpage size by 31%
* Expand Status 2 with Build date/time and core version
* Fix webserver redirection when not in WifiManager mode (arendst#156)
* Add command ButtonRestrict On/Off to restrict access to button hold
and button multi press options above 2 (arendst#161)
* Fix DS18S20 negative temperature readings (arendst#165)
* Fix crlf compilation error due to bad syntax (arendst#144, arendst#167)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants