GRASS Programmer's Manual
6.4.2(2012)
Main Page
Related Pages
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
xdrchar.c
Go to the documentation of this file.
1
#include "
xdr.h
"
2
3
4
int
db__send_char
(
int
d)
5
{
6
int
stat = DB_OK;
7
char
c = (char)d;
8
9
if
(!
db__send
(&c,
sizeof
(c)))
10
stat = DB_PROTOCOL_ERR;
11
12
if
(stat == DB_PROTOCOL_ERR)
13
db_protocol_error
();
14
15
return
stat;
16
}
17
18
19
int
db__recv_char
(
char
*d)
20
{
21
int
stat = DB_OK;
22
23
if
(!
db__recv
(d,
sizeof
(*d)))
24
stat = DB_PROTOCOL_ERR;
25
26
if
(stat == DB_PROTOCOL_ERR)
27
db_protocol_error
();
28
29
return
stat;
30
}
lib
db
dbmi_base
xdrchar.c
Generated on Sun Sep 9 2012 18:55:35 for GRASS Programmer's Manual by
1.8.1.2