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

Side by Side Diff: mozilla/nsprpub/pr/src/io/prscanf.c

Issue 12089033: Update to NSPR 4.9.5 Beta 2, part 2: actual changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/nss/
Patch Set: Created 7 years, 10 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 | « mozilla/nsprpub/pr/src/io/prmapopt.c ('k') | mozilla/nsprpub/pr/src/linking/prlink.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 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public 2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this 3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5 5
6 /* 6 /*
7 * Scan functions for NSPR types 7 * Scan functions for NSPR types
8 * 8 *
9 * Author: Wan-Teh Chang 9 * Author: Wan-Teh Chang
10 * 10 *
11 * Acknowledgment: The implementation is inspired by the source code 11 * Acknowledgment: The implementation is inspired by the source code
12 * in P.J. Plauger's "The Standard C Library," Prentice-Hall, 1992. 12 * in P.J. Plauger's "The Standard C Library," Prentice-Hall, 1992.
13 */ 13 */
14 14
15 #include <limits.h> 15 #include <limits.h>
16 #include <ctype.h> 16 #include <ctype.h>
17 #include <string.h> 17 #include <string.h>
18 #include <stdlib.h> 18 #include <stdlib.h>
19 #ifdef SUNOS4
20 #include "md/sunos4.h" /* for strtoul */
21 #endif
22 #include "prprf.h" 19 #include "prprf.h"
23 #include "prdtoa.h" 20 #include "prdtoa.h"
24 #include "prlog.h" 21 #include "prlog.h"
25 #include "prerror.h" 22 #include "prerror.h"
26 23
27 /* 24 /*
28 * A function that reads a character from 'stream'. 25 * A function that reads a character from 'stream'.
29 * Returns the character read, or EOF if end of stream is reached. 26 * Returns the character read, or EOF if end of stream is reached.
30 */ 27 */
31 typedef int (*_PRGetCharFN)(void *stream); 28 typedef int (*_PRGetCharFN)(void *stream);
(...skipping 596 matching lines...) Expand 10 before | Expand all | Expand 10 after
628 ScanfState state; 625 ScanfState state;
629 626
630 state.get = &StringGetChar; 627 state.get = &StringGetChar;
631 state.unget = &StringUngetChar; 628 state.unget = &StringUngetChar;
632 state.stream = (void *) &buf; 629 state.stream = (void *) &buf;
633 va_start(state.ap, fmt); 630 va_start(state.ap, fmt);
634 rv = DoScanf(&state, fmt); 631 rv = DoScanf(&state, fmt);
635 va_end(state.ap); 632 va_end(state.ap);
636 return rv; 633 return rv;
637 } 634 }
OLDNEW
« no previous file with comments | « mozilla/nsprpub/pr/src/io/prmapopt.c ('k') | mozilla/nsprpub/pr/src/linking/prlink.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698