aboutsummaryrefslogtreecommitdiffstats
path: root/com32/elflink/ldlinux
diff options
context:
space:
mode:
authorMatt Fleming <matt.fleming@intel.com>2012-04-02 13:36:17 +0100
committerMatt Fleming <matt.fleming@intel.com>2012-04-17 10:58:33 +0100
commitf1be23e2251520c35f8581f4612f2356ef6de0ee (patch)
tree26fac0074d4f96fb36f8eda7c4a75dd6d7deb6d5 /com32/elflink/ldlinux
parent0132132022e73d5720121695a9b96fe2eb264d80 (diff)
downloadsyslinux-f1be23e2251520c35f8581f4612f2356ef6de0ee.tar.gz
syslinux-f1be23e2251520c35f8581f4612f2356ef6de0ee.tar.xz
syslinux-f1be23e2251520c35f8581f4612f2356ef6de0ee.zip
ldlinux: Match arg types to function prototypes
Change the types of some local variables to match the type in the function prototypes, thereby avoiding the following warnings, ldlinux.c:132:2: warning: pointer targets in passing argument 2 of ‘syslinux_getadv’ differ in signedness ../../../com32/include/syslinux/adv.h:55:22: note: expected ‘size_t *’ but argument is of type ‘int *’ ldlinux.c:132:6: warning: assignment discards qualifiers from pointer target type ldlinux.c:156:3: warning: pointer targets in passing argument 1 of ‘load_kernel’ differ in signedness ldlinux.c:58:13: note: expected ‘const char *’ but argument is of type ‘uint8_t *’ Signed-off-by: Matt Fleming <matt.fleming@intel.com>
Diffstat (limited to 'com32/elflink/ldlinux')
-rw-r--r--com32/elflink/ldlinux/ldlinux.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/com32/elflink/ldlinux/ldlinux.c b/com32/elflink/ldlinux/ldlinux.c
index 3cf6513d..55886be9 100644
--- a/com32/elflink/ldlinux/ldlinux.c
+++ b/com32/elflink/ldlinux/ldlinux.c
@@ -117,8 +117,8 @@ static void enter_cmdline(void)
int main(int argc, char **argv)
{
com32sys_t ireg, oreg;
- uint8_t *adv;
- int count = 0;
+ const void *adv;
+ size_t count = 0;
char *config_argv[2] = { NULL, NULL };
openconsole(&dev_rawcon_r, &dev_ansiserial_w);
@@ -134,10 +134,11 @@ int main(int argc, char **argv)
* We apparently have a boot-once set; clear it and
* then execute the boot-once.
*/
- uint8_t *src, *dst, *cmdline;
- int i;
+ const char *cmdline;
+ char *src, *dst;
+ size_t i;
- src = adv;
+ src = (char *)adv;
cmdline = dst = malloc(count + 1);
if (!dst) {
printf("Failed to allocate memory for ADV\n");