mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2025-11-25 18:55:24 +00:00
More cleanup of MSVC errors
Review URL: http://codereview.chromium.org/2871019
This commit is contained in:
2
Makefile
2
Makefile
@@ -8,7 +8,7 @@ export CFLAGS = -Wall -DNDEBUG -O3 -Werror -DCHROMEOS_ENVIRONMENT
|
|||||||
export TOP = $(shell pwd)
|
export TOP = $(shell pwd)
|
||||||
export FWDIR=$(TOP)/firmware
|
export FWDIR=$(TOP)/firmware
|
||||||
export HOSTDIR=$(TOP)/host
|
export HOSTDIR=$(TOP)/host
|
||||||
export INCLUDES = -I$(FWDIR)/include
|
export INCLUDES = -I$(FWDIR)/include -I$(FWDIR)/stub/include
|
||||||
|
|
||||||
export BUILD = ${TOP}/build
|
export BUILD = ${TOP}/build
|
||||||
export FWLIB = ${BUILD}/vboot_fw.a
|
export FWLIB = ${BUILD}/vboot_fw.a
|
||||||
|
|||||||
@@ -12,7 +12,8 @@ INCLUDES = \
|
|||||||
-I$(FWTOP)/include \
|
-I$(FWTOP)/include \
|
||||||
-I$(LIBDIR)/include \
|
-I$(LIBDIR)/include \
|
||||||
-I$(LIBDIR)/cgptlib/include \
|
-I$(LIBDIR)/cgptlib/include \
|
||||||
-I$(LIBDIR)/cryptolib/include
|
-I$(LIBDIR)/cryptolib/include \
|
||||||
|
-I$(STUBDIR)/include
|
||||||
|
|
||||||
|
|
||||||
# find ./lib -iname '*.c' | sort
|
# find ./lib -iname '*.c' | sort
|
||||||
|
|||||||
@@ -31,7 +31,7 @@
|
|||||||
#define UINT64_MULT32(v, multby) (((uint64_t)(v)) * ((uint32_t)(multby)))
|
#define UINT64_MULT32(v, multby) (((uint64_t)(v)) * ((uint32_t)(multby)))
|
||||||
|
|
||||||
#else
|
#else
|
||||||
#include "stub/biosincludes.h"
|
#include "biosincludes.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif /* VBOOT_REFERENCE_SYSINCLUDES_H_ */
|
#endif /* VBOOT_REFERENCE_SYSINCLUDES_H_ */
|
||||||
|
|||||||
@@ -130,7 +130,7 @@ int CheckEntries(GptEntry* entries, GptHeader* h, uint64_t drive_sectors) {
|
|||||||
/* Check all entries. */
|
/* Check all entries. */
|
||||||
for (i = 0, entry = entries; i < h->number_of_entries; i++, entry++) {
|
for (i = 0, entry = entries; i < h->number_of_entries; i++, entry++) {
|
||||||
GptEntry* e2;
|
GptEntry* e2;
|
||||||
int i2;
|
uint32_t i2;
|
||||||
|
|
||||||
if (IsUnusedEntry(entry))
|
if (IsUnusedEntry(entry))
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
@@ -83,7 +83,7 @@ typedef struct {
|
|||||||
uint32_t number_of_entries;
|
uint32_t number_of_entries;
|
||||||
uint32_t size_of_entry;
|
uint32_t size_of_entry;
|
||||||
uint32_t entries_crc32;
|
uint32_t entries_crc32;
|
||||||
uint8_t reserved_padding[]; /* entire sector reserved for header */
|
/* Remainder of sector is reserved and should be 0 */
|
||||||
} __attribute__((packed)) GptHeader;
|
} __attribute__((packed)) GptHeader;
|
||||||
|
|
||||||
/* GPT partition entry defines the starting and ending LBAs of a partition.
|
/* GPT partition entry defines the starting and ending LBAs of a partition.
|
||||||
@@ -104,7 +104,7 @@ typedef struct {
|
|||||||
uint64_t whole;
|
uint64_t whole;
|
||||||
} attrs;
|
} attrs;
|
||||||
uint16_t name[36]; /* UTF-16 encoded partition name */
|
uint16_t name[36]; /* UTF-16 encoded partition name */
|
||||||
uint8_t reserved[]; /* nothing, really */
|
/* Remainder of entry is reserved and should be 0 */
|
||||||
} __attribute__((packed)) GptEntry;
|
} __attribute__((packed)) GptEntry;
|
||||||
|
|
||||||
#endif /* VBOOT_REFERENCE_CGPTLIB_GPT_H_ */
|
#endif /* VBOOT_REFERENCE_CGPTLIB_GPT_H_ */
|
||||||
|
|||||||
@@ -170,7 +170,7 @@ int RSAVerify(const RSAPublicKey *key,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Check if digest matches. */
|
/* Check if digest matches. */
|
||||||
for (; i < sig_len; ++i) {
|
for (; i < (int)sig_len; ++i) {
|
||||||
if (buf[i] != *hash++) {
|
if (buf[i] != *hash++) {
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
/* TODO(gauravsh): Replace with a macro call for logging. */
|
/* TODO(gauravsh): Replace with a macro call for logging. */
|
||||||
|
|||||||
Reference in New Issue
Block a user