Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(62)

Side by Side Diff: nss/lib/freebl/md5.c

Issue 16132005: Allow NSS to be built with NO_NSPR_10_SUPPORT. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/nss/
Patch Set: Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « nss/lib/freebl/ec.c ('k') | nss/lib/freebl/mpi/mpmontg.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifdef FREEBL_NO_DEPEND 5 #ifdef FREEBL_NO_DEPEND
6 #include "stubs.h" 6 #include "stubs.h"
7 #endif 7 #endif
8 8
9 #include "prerr.h" 9 #include "prerr.h"
10 #include "secerr.h" 10 #include "secerr.h"
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 191
192 #define inBuf u.b 192 #define inBuf u.b
193 193
194 SECStatus 194 SECStatus
195 MD5_Hash(unsigned char *dest, const char *src) 195 MD5_Hash(unsigned char *dest, const char *src)
196 { 196 {
197 return MD5_HashBuf(dest, (const unsigned char *)src, PORT_Strlen(src)); 197 return MD5_HashBuf(dest, (const unsigned char *)src, PORT_Strlen(src));
198 } 198 }
199 199
200 SECStatus 200 SECStatus
201 MD5_HashBuf(unsigned char *dest, const unsigned char *src, uint32 src_length) 201 MD5_HashBuf(unsigned char *dest, const unsigned char *src, PRUint32 src_length)
202 { 202 {
203 unsigned int len; 203 unsigned int len;
204 MD5Context cx; 204 MD5Context cx;
205 205
206 MD5_Begin(&cx); 206 MD5_Begin(&cx);
207 MD5_Update(&cx, src, src_length); 207 MD5_Update(&cx, src, src_length);
208 MD5_End(&cx, dest, &len, MD5_HASH_LEN); 208 MD5_End(&cx, dest, &len, MD5_HASH_LEN);
209 memset(&cx, 0, sizeof cx); 209 memset(&cx, 0, sizeof cx);
210 return SECSuccess; 210 return SECSuccess;
211 } 211 }
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after
585 void MD5_Clone(MD5Context *dest, MD5Context *src) 585 void MD5_Clone(MD5Context *dest, MD5Context *src)
586 { 586 {
587 memcpy(dest, src, sizeof *dest); 587 memcpy(dest, src, sizeof *dest);
588 } 588 }
589 589
590 void 590 void
591 MD5_TraceState(MD5Context *cx) 591 MD5_TraceState(MD5Context *cx)
592 { 592 {
593 PORT_SetError(PR_NOT_IMPLEMENTED_ERROR); 593 PORT_SetError(PR_NOT_IMPLEMENTED_ERROR);
594 } 594 }
OLDNEW
« no previous file with comments | « nss/lib/freebl/ec.c ('k') | nss/lib/freebl/mpi/mpmontg.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698