Merge branch 'antmak-fix_fallthrough_warn' (#202)
This commit is contained in:
commit
135208fad4
@ -21,10 +21,11 @@ Release 2.2.? ???????????????????
|
|||||||
#178 #179 CMake: Use GNUInstallDirs module to set proper defaults for
|
#178 #179 CMake: Use GNUInstallDirs module to set proper defaults for
|
||||||
install directories
|
install directories
|
||||||
#180 Windows: Fix compilation of test suite for Visual Studio 2008
|
#180 Windows: Fix compilation of test suite for Visual Studio 2008
|
||||||
#131 #173 Address compiler warnings
|
#131 #173 #202 Address compiler warnings
|
||||||
#187 #190 #200 Fix miscellaneous typos
|
#187 #190 #200 Fix miscellaneous typos
|
||||||
|
|
||||||
Special thanks to:
|
Special thanks to:
|
||||||
|
Anton Maklakov
|
||||||
Benjamin Peterson
|
Benjamin Peterson
|
||||||
Brad King
|
Brad King
|
||||||
Franek Korta
|
Franek Korta
|
||||||
|
@ -11,6 +11,9 @@
|
|||||||
* --------------------------------------------------------------------------
|
* --------------------------------------------------------------------------
|
||||||
* HISTORY:
|
* HISTORY:
|
||||||
*
|
*
|
||||||
|
* 2018-07-08 (Anton Maklakov)
|
||||||
|
* - Add "fall through" markers for GCC's -Wimplicit-fallthrough
|
||||||
|
*
|
||||||
* 2017-11-03 (Sebastian Pipping)
|
* 2017-11-03 (Sebastian Pipping)
|
||||||
* - Hide sip_tobin and sip_binof unless SIPHASH_TOBIN macro is defined
|
* - Hide sip_tobin and sip_binof unless SIPHASH_TOBIN macro is defined
|
||||||
*
|
*
|
||||||
@ -238,12 +241,19 @@ static uint64_t sip24_final(struct siphash *H) {
|
|||||||
|
|
||||||
switch (left) {
|
switch (left) {
|
||||||
case 7: b |= (uint64_t)H->buf[6] << 48;
|
case 7: b |= (uint64_t)H->buf[6] << 48;
|
||||||
|
/* fall through */
|
||||||
case 6: b |= (uint64_t)H->buf[5] << 40;
|
case 6: b |= (uint64_t)H->buf[5] << 40;
|
||||||
|
/* fall through */
|
||||||
case 5: b |= (uint64_t)H->buf[4] << 32;
|
case 5: b |= (uint64_t)H->buf[4] << 32;
|
||||||
|
/* fall through */
|
||||||
case 4: b |= (uint64_t)H->buf[3] << 24;
|
case 4: b |= (uint64_t)H->buf[3] << 24;
|
||||||
|
/* fall through */
|
||||||
case 3: b |= (uint64_t)H->buf[2] << 16;
|
case 3: b |= (uint64_t)H->buf[2] << 16;
|
||||||
|
/* fall through */
|
||||||
case 2: b |= (uint64_t)H->buf[1] << 8;
|
case 2: b |= (uint64_t)H->buf[1] << 8;
|
||||||
|
/* fall through */
|
||||||
case 1: b |= (uint64_t)H->buf[0] << 0;
|
case 1: b |= (uint64_t)H->buf[0] << 0;
|
||||||
|
/* fall through */
|
||||||
case 0: break;
|
case 0: break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1820,6 +1820,7 @@ XML_Parse(XML_Parser parser, const char *s, int len, int isFinal)
|
|||||||
parser->m_errorCode = XML_ERROR_NO_MEMORY;
|
parser->m_errorCode = XML_ERROR_NO_MEMORY;
|
||||||
return XML_STATUS_ERROR;
|
return XML_STATUS_ERROR;
|
||||||
}
|
}
|
||||||
|
/* fall through */
|
||||||
default:
|
default:
|
||||||
parser->m_parsingStatus.parsing = XML_PARSING;
|
parser->m_parsingStatus.parsing = XML_PARSING;
|
||||||
}
|
}
|
||||||
@ -1969,6 +1970,7 @@ XML_ParseBuffer(XML_Parser parser, int len, int isFinal)
|
|||||||
parser->m_errorCode = XML_ERROR_NO_MEMORY;
|
parser->m_errorCode = XML_ERROR_NO_MEMORY;
|
||||||
return XML_STATUS_ERROR;
|
return XML_STATUS_ERROR;
|
||||||
}
|
}
|
||||||
|
/* fall through */
|
||||||
default:
|
default:
|
||||||
parser->m_parsingStatus.parsing = XML_PARSING;
|
parser->m_parsingStatus.parsing = XML_PARSING;
|
||||||
}
|
}
|
||||||
@ -4746,8 +4748,8 @@ doProlog(XML_Parser parser,
|
|||||||
return XML_ERROR_NO_MEMORY;
|
return XML_ERROR_NO_MEMORY;
|
||||||
parser->m_declEntity->publicId = NULL;
|
parser->m_declEntity->publicId = NULL;
|
||||||
}
|
}
|
||||||
/* fall through */
|
|
||||||
#endif /* XML_DTD */
|
#endif /* XML_DTD */
|
||||||
|
/* fall through */
|
||||||
case XML_ROLE_ENTITY_SYSTEM_ID:
|
case XML_ROLE_ENTITY_SYSTEM_ID:
|
||||||
if (dtd->keepProcessing && parser->m_declEntity) {
|
if (dtd->keepProcessing && parser->m_declEntity) {
|
||||||
parser->m_declEntity->systemId = poolStoreString(&dtd->pool, enc,
|
parser->m_declEntity->systemId = poolStoreString(&dtd->pool, enc,
|
||||||
|
@ -74,6 +74,7 @@
|
|||||||
*nextTokPtr = ptr; \
|
*nextTokPtr = ptr; \
|
||||||
return XML_TOK_INVALID; \
|
return XML_TOK_INVALID; \
|
||||||
} \
|
} \
|
||||||
|
/* fall through */ \
|
||||||
case BT_NMSTRT: \
|
case BT_NMSTRT: \
|
||||||
case BT_HEX: \
|
case BT_HEX: \
|
||||||
case BT_DIGIT: \
|
case BT_DIGIT: \
|
||||||
@ -102,6 +103,7 @@
|
|||||||
*nextTokPtr = ptr; \
|
*nextTokPtr = ptr; \
|
||||||
return XML_TOK_INVALID; \
|
return XML_TOK_INVALID; \
|
||||||
} \
|
} \
|
||||||
|
/* fall through */ \
|
||||||
case BT_NMSTRT: \
|
case BT_NMSTRT: \
|
||||||
case BT_HEX: \
|
case BT_HEX: \
|
||||||
ptr += MINBPC(enc); \
|
ptr += MINBPC(enc); \
|
||||||
@ -602,7 +604,7 @@ PREFIX(scanAtts)(const ENCODING *enc, const char *ptr, const char *end,
|
|||||||
return XML_TOK_INVALID;
|
return XML_TOK_INVALID;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* fall through */
|
/* fall through */
|
||||||
case BT_EQUALS:
|
case BT_EQUALS:
|
||||||
{
|
{
|
||||||
int open;
|
int open;
|
||||||
@ -1442,6 +1444,7 @@ PREFIX(isPublicId)(const ENCODING *enc, const char *ptr, const char *end,
|
|||||||
case BT_NMSTRT:
|
case BT_NMSTRT:
|
||||||
if (!(BYTE_TO_ASCII(enc, ptr) & ~0x7f))
|
if (!(BYTE_TO_ASCII(enc, ptr) & ~0x7f))
|
||||||
break;
|
break;
|
||||||
|
/* fall through */
|
||||||
default:
|
default:
|
||||||
switch (BYTE_TO_ASCII(enc, ptr)) {
|
switch (BYTE_TO_ASCII(enc, ptr)) {
|
||||||
case 0x24: /* $ */
|
case 0x24: /* $ */
|
||||||
|
Loading…
Reference in New Issue
Block a user