Changeset 31651


Ignore:
Timestamp:
Mar 14, 2017, 10:21:02 AM (4 months ago)
Author:
brainslayer
Message:

fixes country selection

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/router/services/sysinit/sysinit-ipq806x.c

    r31649 r31651  
    358358        fread(buf, 1, 18, fp);
    359359        pclose(fp);
    360         buf[sizeof(defstr) + 2] = 0;
     360        buf[strlen(defstr) + 2] = 0;
    361361        memset(c, 0, sizeof(c));
    362         strncpy(c, &buf[sizeof(defstr)], 2);
     362        strncpy(c, &buf[strlen(defstr)], 2);
     363//      fprintf(stderr,"isostr %s\n",buf);
     364        fprintf(stderr,"iso %s\n",c);
    363365        char *ctry = getCountryByIso(c);
     366        fprintf(stderr,"country %s\n",ctry);
    364367        if (!ctry)
    365368                return;
Note: See TracChangeset for help on using the changeset viewer.