Mercurial > flash_v2
comparison packages/redboot/current/include/redboot.h @ 1605:43a89c18d005
Add checking (assert) for size of option arrays. Also fix port for TFTP on little endian systems.
| author | gthomas |
|---|---|
| date | Fri, 23 Apr 2004 20:38:17 +0000 |
| parents | 08edfb52f9cd |
| children | 59fbd6362c2b |
comparison
equal
deleted
inserted
replaced
| 1604:bc88a3357a79 | 1605:43a89c18d005 |
|---|---|
| 7 //========================================================================== | 7 //========================================================================== |
| 8 //####ECOSGPLCOPYRIGHTBEGIN#### | 8 //####ECOSGPLCOPYRIGHTBEGIN#### |
| 9 // ------------------------------------------- | 9 // ------------------------------------------- |
| 10 // This file is part of eCos, the Embedded Configurable Operating System. | 10 // This file is part of eCos, the Embedded Configurable Operating System. |
| 11 // Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc. | 11 // Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc. |
| 12 // Copyright (C) 2002, 2003 Gary Thomas | 12 // Copyright (C) 2002, 2003, 2004 Gary Thomas |
| 13 // | 13 // |
| 14 // eCos is free software; you can redistribute it and/or modify it under | 14 // eCos is free software; you can redistribute it and/or modify it under |
| 15 // the terms of the GNU General Public License as published by the Free | 15 // the terms of the GNU General Public License as published by the Free |
| 16 // Software Foundation; either version 2 or (at your option) any later version. | 16 // Software Foundation; either version 2 or (at your option) any later version. |
| 17 // | 17 // |
| 293 void *arg; | 293 void *arg; |
| 294 bool *arg_set; | 294 bool *arg_set; |
| 295 char *name; | 295 char *name; |
| 296 }; | 296 }; |
| 297 | 297 |
| 298 #define NUM_ELEMS(s) (sizeof(s)/sizeof(s[0])) | |
| 299 | |
| 298 #define OPTION_ARG_TYPE_NUM 0 // Numeric data | 300 #define OPTION_ARG_TYPE_NUM 0 // Numeric data |
| 299 #define OPTION_ARG_TYPE_STR 1 // Generic string | 301 #define OPTION_ARG_TYPE_STR 1 // Generic string |
| 300 #define OPTION_ARG_TYPE_FLG 2 // Flag only | 302 #define OPTION_ARG_TYPE_FLG 2 // Flag only |
| 301 | 303 |
| 302 // Command line parsing | 304 // Command line parsing |
