mirror of
https://github.com/php/php-src.git
synced 2025-08-18 15:08:55 +02:00
- ws + cs + nuke a warning
This commit is contained in:
parent
766c8a9d2b
commit
7eff073be1
1 changed files with 10 additions and 10 deletions
|
@ -23,13 +23,13 @@
|
||||||
#include "base64.h"
|
#include "base64.h"
|
||||||
|
|
||||||
/* {{{ base64 tables */
|
/* {{{ base64 tables */
|
||||||
static const char base64_table[] =
|
static const char base64_table[] = {
|
||||||
{ 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M',
|
'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M',
|
||||||
'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z',
|
'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z',
|
||||||
'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm',
|
'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm',
|
||||||
'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z',
|
'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z',
|
||||||
'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '+', '/', '\0'
|
'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '+', '/', '\0'
|
||||||
};
|
};
|
||||||
|
|
||||||
static const char base64_pad = '=';
|
static const char base64_pad = '=';
|
||||||
|
|
||||||
|
@ -233,7 +233,7 @@ PHP_FUNCTION(base64_decode)
|
||||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &str, &str_len, &strict) == FAILURE) {
|
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &str, &str_len, &strict) == FAILURE) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
result = php_base64_decode_ex(str, str_len, &ret_length, strict);
|
result = php_base64_decode_ex((unsigned char*)str, str_len, &ret_length, strict);
|
||||||
if (result != NULL) {
|
if (result != NULL) {
|
||||||
RETVAL_STRINGL((char*)result, ret_length, 0);
|
RETVAL_STRINGL((char*)result, ret_length, 0);
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue