| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 3717be2 commit 20ec1a7
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1240,7 +1240,7 @@ binascii_b2a_ascii85_impl(PyObject *module, Py_buffer *data, int foldspaces, | |||
| 1240 | 1240 | ||
| 1241 | 1241 | /* Encode all full-length chunks. */ | |
| 1242 | 1242 | for (; bin_len >= 4; bin_len -= 4, bin_data += 4) { | |
| 1243 | - uint32_t leftchar = (bin_data[0] << 24) | (bin_data[1] << 16) | | ||
| 1243 | + uint32_t leftchar = ((uint32_t)bin_data[0] << 24) | (bin_data[1] << 16) | | ||
| 1244 | 1244 | (bin_data[2] << 8) | bin_data[3]; | |
| 1245 | 1245 | if (leftchar == BASE85_A85_Z) { | |
| 1246 | 1246 | *ascii_data++ = 'z'; | |
@@ -1481,7 +1481,7 @@ binascii_b2a_base85_impl(PyObject *module, Py_buffer *data, int pad, | |||
| 1481 | 1481 | ||
| 1482 | 1482 | /* Encode all full-length chunks. */ | |
| 1483 | 1483 | for (; bin_len >= 4; bin_len -= 4, bin_data += 4) { | |
| 1484 | - uint32_t leftchar = (bin_data[0] << 24) | (bin_data[1] << 16) | | ||
| 1484 | + uint32_t leftchar = ((uint32_t)bin_data[0] << 24) | (bin_data[1] << 16) | | ||
| 1485 | 1485 | (bin_data[2] << 8) | bin_data[3]; | |
| 1486 | 1486 | ||
| 1487 | 1487 | ascii_data[4] = table_b2a[leftchar % 85]; | |
| Back | FazBrowse Home | New Git URL |
0 commit comments