OLD | NEW |
1 /* This Source Code Form is subject to the terms of the Mozilla Public | 1 /* This Source Code Form is subject to the terms of the Mozilla Public |
2 * License, v. 2.0. If a copy of the MPL was not distributed with this | 2 * License, v. 2.0. If a copy of the MPL was not distributed with this |
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | 3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ |
4 | 4 |
5 /* | 5 /* |
6 * Base64 decoding (ascii to binary). | 6 * Base64 decoding (ascii to binary). |
7 * | |
8 * $Id$ | |
9 */ | 7 */ |
10 | 8 |
11 #include "nssb64.h" | 9 #include "nssb64.h" |
12 #include "nspr.h" | 10 #include "nspr.h" |
13 #include "secitem.h" | 11 #include "secitem.h" |
14 #include "secerr.h" | 12 #include "secerr.h" |
15 | 13 |
16 /* | 14 /* |
17 * XXX We want this basic support to go into NSPR (the PL part). | 15 * XXX We want this basic support to go into NSPR (the PL part). |
18 * Until that can happen, the PL interface is going to be kept entirely | 16 * Until that can happen, the PL interface is going to be kept entirely |
(...skipping 810 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
829 binary_item->len = 0; | 827 binary_item->len = 0; |
830 | 828 |
831 dummy = NSSBase64_DecodeBuffer (NULL, binary_item, ascii, | 829 dummy = NSSBase64_DecodeBuffer (NULL, binary_item, ascii, |
832 (PRUint32) PORT_Strlen(ascii)); | 830 (PRUint32) PORT_Strlen(ascii)); |
833 | 831 |
834 if (dummy == NULL) | 832 if (dummy == NULL) |
835 return SECFailure; | 833 return SECFailure; |
836 | 834 |
837 return SECSuccess; | 835 return SECSuccess; |
838 } | 836 } |
OLD | NEW |