GRASS GIS 7 Programmer's Manual
7.9.dev(2021)-e5379bbd7
Main Page
Related Pages
+
Data Structures
Data Structures
Class Hierarchy
+
Data Fields
+
All
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
+
Functions
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
~
+
Variables
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Related Functions
+
Files
File List
+
Globals
+
All
_
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Functions
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
+
Variables
_
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
w
x
y
+
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
o
p
r
s
t
u
v
w
y
z
+
Enumerations
a
c
d
e
h
l
m
n
o
p
r
s
t
v
y
+
Enumerator
a
b
c
d
e
f
g
h
i
l
m
n
o
p
r
s
t
u
v
w
+
Macros
_
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
•
All
Data Structures
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
strip.c
Go to the documentation of this file.
1
/*!
2
\file lib/db/dbmi_base/strip.c
3
4
\brief DBMI Library (base) - strip strings
5
6
(C) 1999-2009, 2011 by the GRASS Development Team
7
8
This program is free software under the GNU General Public License
9
(>=v2). Read the file COPYING that comes with GRASS for details.
10
11
\author Joel Jones (CERL/UIUC), Radim Blazek
12
\author Doxygenized by Martin Landa <landa.martin gmail.com> (2011)
13
*/
14
15
#include <
grass/dbmi.h
>
16
17
/*!
18
\brief Strip given string
19
20
'buf' is rewritten in place with leading and trailing white
21
space removed.
22
23
\param buf string buffer
24
*/
25
void
db_strip
(
char
*buf)
26
{
27
char
*a, *
b
;
28
29
/* remove leading white space */
30
for
(a = b = buf; *a ==
' '
|| *a ==
'\t'
; a++) ;
31
if
(a != b)
32
while
((*b++ = *a++)) ;
33
34
/* remove trailing white space */
35
for
(a = buf; *a; a++) ;
36
if
(a != buf) {
37
for
(a--; *a ==
' '
|| *a ==
'\t'
; a--) ;
38
a++;
39
*a = 0;
40
}
41
}
dbmi.h
b
double b
Definition:
r_raster.c:39
db_strip
void db_strip(char *buf)
Strip given string.
Definition:
strip.c:25
lib
db
dbmi_base
strip.c
Generated on Mon May 31 2021 05:21:32 for GRASS GIS 7 Programmer's Manual by
1.8.13