aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Fleming <matt.fleming@intel.com>2012-08-02 14:51:03 +0100
committerMatt Fleming <matt.fleming@intel.com>2012-08-02 14:51:03 +0100
commitb6b97c945d171aebc30510249a77581cd57fc8e7 (patch)
tree2276324828d74d160db98ec10c2c9966ac7529a0
parent0d6f330878173c7ba45b884f3e41ce40b917c73c (diff)
downloadsyslinux-b6b97c945d171aebc30510249a77581cd57fc8e7.tar.gz
syslinux-b6b97c945d171aebc30510249a77581cd57fc8e7.tar.xz
syslinux-b6b97c945d171aebc30510249a77581cd57fc8e7.zip
core: Change numIPAppends data type
For EFI we don't have the opportunity to mess with the object type of 'numIPAppends' via assembly as is done for BIOS - we need to do it all in C. So change numIPAppends to size_t to accurately reflect its use. Without this change the loop in __syslinux_get_ipappend_strings() actually uses the address of numIPAppends instead of any value stored there because it's a char array. Signed-off-by: Matt Fleming <matt.fleming@intel.com>
-rw-r--r--core/include/core.h2
-rw-r--r--efi/main.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/core/include/core.h b/core/include/core.h
index c665d790..be687f8b 100644
--- a/core/include/core.h
+++ b/core/include/core.h
@@ -36,7 +36,7 @@ extern unsigned int __bcopyxx_len;
extern uint8_t KbdMap[256];
extern const uint16_t IPAppends[];
-extern const char numIPAppends[];
+extern size_t numIPAppends;
extern uint16_t SerialPort;
extern uint16_t BaudDivisor;
diff --git a/efi/main.c b/efi/main.c
index f98d95c3..379b475c 100644
--- a/efi/main.c
+++ b/efi/main.c
@@ -81,7 +81,7 @@ void pxenv(void)
{
}
-const char numIPAppends[4];
+size_t numIPAppends = 0;
const uint16_t IPAppends[32];
uint16_t BIOS_fbm = 1;
far_ptr_t InitStack;