Skip to content
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

Problem with AM/PM setting upon Make #182

Open
cebab54 opened this issue Nov 9, 2020 · 3 comments
Open

Problem with AM/PM setting upon Make #182

cebab54 opened this issue Nov 9, 2020 · 3 comments

Comments

@cebab54
Copy link

cebab54 commented Nov 9, 2020

Hi Nick

When I make sprinklers_pi and the config_h file is NOT set to 24H times (ie as out of the box) it throws the following String error:

settings.h:146:12: note: ‘sprintf’ output between 8 and 11 bytes into a destination of size 10
sprintf(buff, "%d:%.2d %s",
~~~~~~~^~~~~~~~~~~~~~~~~~~~
(h%12 == 0 ? 12 : h%12),
~~~~~~~~~~~~~~~~~~~~~~~~
x%60,
~~~~~
(h < 12 ? "AM" : "PM"));
~~~~~~~~~~~~~~~~~~~~~~~
Building target: sprinklers_pi

If I set the Time to the 24HR format in config_h then this error goes away

@cebab54 cebab54 changed the title Problem with AM/PM setting upon Compile Problem with AM/PM setting upon Make Nov 9, 2020
@nhorvath
Copy link
Collaborator

nhorvath commented Nov 9, 2020

I personally use the AM/PM setting and don't have this issue. What timezone are you in?

@nhorvath
Copy link
Collaborator

nhorvath commented Nov 9, 2020

I don't know why it would say between 8 and 11 bytes either. "00:00 AM" is 8 bytes, I'm not sure how it would become 11 bytes.

@nhorvath
Copy link
Collaborator

nhorvath commented Nov 9, 2020

all this aside, it's a note... not even a warning let alone an error. Is this actually causing an issue with compilation? Please make clean then make and post the whole log.

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

No branches or pull requests

2 participants