summaryrefslogtreecommitdiff
path: root/gpxe/src/usr/pxemenu.c
diff options
context:
space:
mode:
Diffstat (limited to 'gpxe/src/usr/pxemenu.c')
-rw-r--r--gpxe/src/usr/pxemenu.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gpxe/src/usr/pxemenu.c b/gpxe/src/usr/pxemenu.c
index 793cb624..519c200e 100644
--- a/gpxe/src/usr/pxemenu.c
+++ b/gpxe/src/usr/pxemenu.c
@@ -16,6 +16,8 @@
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
+FILE_LICENCE ( GPL2_OR_LATER );
+
#include <stdint.h>
#include <stdlib.h>
#include <stdio.h>
@@ -151,7 +153,7 @@ static int pxe_menu_parse ( struct pxe_menu **menu ) {
( num_menu_items * sizeof ( (*menu)->items[0] ) ) );
memcpy ( raw_menu_item, raw_menu, raw_menu_len );
for ( i = 0 ; i < num_menu_items ; i++ ) {
- (*menu)->items[i].type = ntohs ( raw_menu_item->type );
+ (*menu)->items[i].type = le16_to_cpu ( raw_menu_item->type );
(*menu)->items[i].desc = raw_menu_item->desc;
/* Set type to 0; this ensures that the description
* for the previous menu item is NUL-terminated.