Subversion Repositories SvarDOS

Rev

Rev 1906 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1906 Rev 1952
Line 173... Line 173...
173
   * own environment, because the kernel's environment might vanish eventually */
173
   * own environment, because the kernel's environment might vanish eventually */
174
  if (cfg->envsiz < 256) cfg->envsiz = 256;
174
  if (cfg->envsiz < 256) cfg->envsiz = 256;
175
 
175
 
176
  e = MK_FP(kernenvseg, 0);
176
  e = MK_FP(kernenvseg, 0);
177
 
177
 
178
  /* move forward until the DRDOS' environment 1Ah terminator is found */
-
 
179
  while (*e != 0x1A) e++;
-
 
180
  e++;
-
 
181
 
-
 
182
  /* next I have the boot key press scancode: either 0x0000, 0x3F00 or 0x4200
-
 
183
   * 0x3F00 means "F5 was pressed" while 0x4200 is for F8 */
-
 
184
  scancode = (void far *)e;
-
 
185
  if (*scancode == 0x3F00) {
-
 
186
    cfg->flags |= FLAG_SKIP_AUTOEXEC;
-
 
187
  } else if (*scancode == 0x4200) {
-
 
188
    cfg->flags |= FLAG_STEPBYSTEP;
-
 
189
  }
-
 
190
 
-
 
191
/*
178
/*
192
  printf("kernel env seg is at %04X and starts with bytes 0x%02X 0x%02X 0x%02X 0x%02X\r\n", kernenvseg, e[0], e[1], e[2], e[3]);
179
  printf("kernel env seg is at %04X and starts with bytes 0x%02X 0x%02X 0x%02X 0x%02X\r\n", kernenvseg, e[0], e[1], e[2], e[3]);
193
  {
180
  {
194
    int i;
181
    int i;
195
    printf("=== KERNEL ENV BEGINS ===\r\n");
182
    printf("=== KERNEL ENV BEGINS ===\r\n");
Line 202... Line 189...
202
      printf("%02X ", e[i]);
189
      printf("%02X ", e[i]);
203
    }
190
    }
204
    printf("\r\n=== DUMP ENDS ===\r\n");
191
    printf("\r\n=== DUMP ENDS ===\r\n");
205
  }
192
  }
206
*/
193
*/
-
 
194
 
-
 
195
  /* move forward until the DRDOS' environment 1Ah terminator is found */
-
 
196
  while (*e != 0x1A) e++;
-
 
197
  e++;
-
 
198
 
-
 
199
  /* next I have the boot key press scancode: either 0x0000, 0x3F00 or 0x4200
-
 
200
   * 0x3F00 means "F5 was pressed" while 0x4200 is for F8 */
-
 
201
  scancode = (void far *)e;
-
 
202
  if (*scancode == 0x3F00) {
-
 
203
    cfg->flags |= FLAG_SKIP_AUTOEXEC;
-
 
204
  } else if (*scancode == 0x4200) {
-
 
205
    cfg->flags |= FLAG_STEPBYSTEP;
-
 
206
  }
207
}
207
}
208
 
208
 
209
 
209
 
210
/* parses command line the hard way (directly from PSP) */
210
/* parses command line the hard way (directly from PSP) */
211
static void parse_argv(struct config *cfg) {
211
static void parse_argv(struct config *cfg) {