Subversion Repositories SvarDOS

Rev

Rev 435 | Rev 533 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 435 Rev 451
Line 66... Line 66...
66
    /* now locate the first non-space: that's where the variable name begins */
66
    /* now locate the first non-space: that's where the variable name begins */
67
    for (; *ptr == ' '; ptr++);
67
    for (; *ptr == ' '; ptr++);
68
    /* copy variable to buff and switch it upercase */
68
    /* copy variable to buff and switch it upercase */
69
    i = 0;
69
    i = 0;
70
    for (; *ptr != '='; ptr++) {
70
    for (; *ptr != '='; ptr++) {
71
      if (*ptr == '\r') goto syntax_err;
71
      if (*ptr == 0) goto syntax_err;
72
      buff[i] = *ptr;
72
      buff[i] = *ptr;
73
      if ((buff[i] >= 'a') && (buff[i] <= 'z')) buff[i] -= ('a' - 'A');
73
      if ((buff[i] >= 'a') && (buff[i] <= 'z')) buff[i] -= ('a' - 'A');
74
      i++;
74
      i++;
75
    }
75
    }
76
 
76
 
77
    /* copy value now */
77
    /* copy value now */
78
    while (*ptr != '\r') {
78
    while (*ptr != 0) {
79
      buff[i++] = *ptr;
79
      buff[i++] = *ptr;
80
      ptr++;
80
      ptr++;
81
    }
81
    }
82
 
82
 
83
    /* terminate buff */
83
    /* terminate buff */