OLD | NEW |
---|---|
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 // Written in NSPR style to also be suitable for adding to the NSS demo suite | 4 // Written in NSPR style to also be suitable for adding to the NSS demo suite |
5 | 5 |
6 #ifndef __MEMIO_H | 6 #ifndef __MEMIO_H |
7 #define __MEMIO_H | 7 #define __MEMIO_H |
8 | 8 |
9 #include <stddef.h> | 9 #include <stddef.h> |
10 | 10 |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
87 const char **buf2, unsigned int *len2); | 87 const char **buf2, unsigned int *len2); |
88 | 88 |
89 /* Tell memio how many bytes were sent to the network. | 89 /* Tell memio how many bytes were sent to the network. |
90 * If bytes_written is < 0, it is treated as an NSPR error code. | 90 * If bytes_written is < 0, it is treated as an NSPR error code. |
91 * See nspr/pr/src/md/unix/unix_errors.c for how to | 91 * See nspr/pr/src/md/unix/unix_errors.c for how to |
92 * map from Unix errors to NSPR error codes. | 92 * map from Unix errors to NSPR error codes. |
93 * On EWOULDBLOCK or the equivalent, don't call this function. | 93 * On EWOULDBLOCK or the equivalent, don't call this function. |
94 */ | 94 */ |
95 void memio_PutWriteResult(memio_Private *secret, int bytes_written); | 95 void memio_PutWriteResult(memio_Private *secret, int bytes_written); |
96 | 96 |
97 /* Returns the last saved write error from memio_PutWriteResult or 0 if there | |
98 * has been no error. | |
wtc
2014/06/17 18:24:06
Please clarify that the error is an NSPR error cod
davidben
2014/06/17 20:27:43
Squashed into memio_GetWriteParams and clarified t
| |
99 */ | |
100 int memio_LastWriteError(memio_Private *secret); | |
101 | |
97 #ifdef __cplusplus | 102 #ifdef __cplusplus |
98 } | 103 } |
99 #endif | 104 #endif |
100 | 105 |
101 #endif | 106 #endif |
OLD | NEW |