Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Nettle
nettle
Commits
268bc83d
Commit
268bc83d
authored
Apr 25, 2014
by
Niels Möller
Browse files
Document that length arguments refer to the destination size.
parent
91d0c1b5
Changes
1
Hide whitespace changes
Inline
Side-by-side
nettle.texinfo
View file @
268bc83d
...
...
@@ -295,9 +295,12 @@ In all functions, strings are represented with an explicit length, of
type @code
{
size
_
t
}
, and a pointer of type @code
{
uint8
_
t *
}
or
@code
{
const uint8
_
t *
}
. For functions that transform one string to
another, the argument order is length, destination pointer and source
pointer. Source and destination areas are of the same length. Source and
destination may be the same, so that you can process strings in place,
but they @emph
{
must not
}
overlap in any other way.
pointer. Source and destination areas are usually of the same length.
When they differ, e.g., for @code
{
ccm
_
encrypt
_
message
}
, the length
argument specifies the size of the destination area. Source and
destination pointers may be equal, so that you can process strings in
place, but source and destination areas @emph
{
must not
}
overlap in any
other way.
Many of the functions lack return value and can never fail. Those
functions which can fail, return one on success and zero on failure.
...
...
@@ -547,7 +550,7 @@ identifiers for other purposes. So avoid doing that.
@defvr Constant SHA512
_
224
_
DIGEST
_
SIZE
@defvrx Constant SHA512
_
256
_
DIGEST
_
SIZE
@defvrx Constant SHA384
_
DIGEST
_
SIZE
The digest size
s
for each variant, i.e., 28, 32, and 48, respectively.
The digest size for each variant, i.e., 28, 32, and 48, respectively.
@end defvr
@defvr Constant SHA512
_
224
_
DATA
_
SIZE
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment