Skip to content

Commit

Permalink
Remove time check
Browse files Browse the repository at this point in the history
This is handled by the MQTT library's require_time setting
  • Loading branch information
rojer committed Sep 9, 2021
1 parent 9699fe5 commit 7d4db66
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions src/mgos_gcp.c
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,6 @@ static void mgos_gcp_mqtt_connect(struct mg_connection *c,
uint64_t iat = (uint64_t) now;
uint64_t ttl = (uint64_t) mgos_sys_config_get_gcp_token_ttl();
uint64_t exp = iat + ttl;
if (exp < 1500000000) {
LOG(LL_ERROR, ("Time is not set, GCP connection will fail. "
"Set the time or make sure SNTP is enabled and working."));
}
state->token_ttl_timer_id =
mgos_set_timer((ttl - 30) * 1000, 0, mgos_gcp_jwt_timeout, state);

Expand Down

0 comments on commit 7d4db66

Please sign in to comment.