Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ISC Open Source Projects
BIND
Commits
8a17d1e7
Commit
8a17d1e7
authored
Feb 01, 1999
by
Mark Andrews
Browse files
added decvalue
parent
d42be4bb
Changes
1
Hide whitespace changes
Inline
Side-by-side
lib/dns/rdata.c
View file @
8a17d1e7
...
...
@@ -15,7 +15,7 @@
* SOFTWARE.
*/
/* $Id: rdata.c,v 1.1
7
1999/0
1/29 08:04:12
marka Exp $ */
/* $Id: rdata.c,v 1.1
8
1999/0
2/01 07:59:43
marka Exp $ */
#include
<config.h>
...
...
@@ -64,6 +64,7 @@ static dns_result_t mem_tobuffer(isc_buffer_t *target, void *base,
unsigned
int
length
);
static
int
compare_region
(
isc_region_t
*
r1
,
isc_region_t
*
r2
);
static
int
hexvalue
(
char
value
);
static
int
decvalue
(
char
value
);
static
dns_result_t
base64_totext
(
isc_region_t
*
source
,
isc_buffer_t
*
target
);
static
dns_result_t
base64_tobuffer
(
isc_lex_t
*
lexer
,
...
...
@@ -685,6 +686,16 @@ hexvalue(char value) {
return
(
s
-
hexdigits
);
}
static
int
decvalue
(
char
value
)
{
char
*
s
;
if
(
!
isascii
(
value
&
0xff
))
return
(
-
1
);
if
((
s
=
strchr
(
decdigits
,
value
))
==
NULL
)
return
(
-
1
);
return
(
s
-
decdigits
);
}
static
const
char
base64
[]
=
"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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