~ubuntu-branches/ubuntu/oneiric/gnupg2/oneiric-updates

« back to all changes in this revision

Viewing changes to gl/strsep.h

  • Committer: Bazaar Package Importer
  • Author(s): Thomas Viehmann
  • Date: 2008-10-04 10:25:53 UTC
  • mfrom: (5.1.15 intrepid)
  • Revision ID: james.westby@ubuntu.com-20081004102553-fv62pp8dsitxli47
Tags: 2.0.9-3.1
* Non-maintainer upload.
* agent/gpg-agent.c: Deinit the threading library before exec'ing
  the command to run in --daemon mode. And because that still doesn't
  restore the sigprocmask, do that manually. Closes: #499569

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* Copyright (C) 2004 Free Software Foundation, Inc.
2
 
 
3
 
   Written by Yoann Vandoorselaere <yoann@prelude-ids.org>.
4
 
 
5
 
   This program is free software; you can redistribute it and/or modify
6
 
   it under the terms of the GNU General Public License as published by
7
 
   the Free Software Foundation; either version 2, or (at your option)
8
 
   any later version.
9
 
 
10
 
   This program is distributed in the hope that it will be useful,
11
 
   but WITHOUT ANY WARRANTY; without even the implied warranty of
12
 
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13
 
   GNU General Public License for more details.
14
 
 
15
 
   You should have received a copy of the GNU General Public License
16
 
   along with this program; if not, write to the Free Software Foundation,
17
 
   Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.  */
18
 
 
19
 
#ifndef GNULIB_STRSEP_H_
20
 
#define GNULIB_STRSEP_H_
21
 
 
22
 
#if HAVE_STRSEP
23
 
 
24
 
/*
25
 
 * Get strsep() declaration.
26
 
 */
27
 
#include <string.h>
28
 
 
29
 
#else
30
 
 
31
 
/* Searches the next delimiter (char listed in DELIM) starting at *STRINGP.
32
 
   If one is found, it is overwritten with a NUL, and *STRINGP is advanced
33
 
   to point to the next char after it.  Otherwise, *STRINGP is set to NULL.
34
 
   If *STRINGP was already NULL, nothing happens.
35
 
   Returns the old value of *STRINGP.
36
 
 
37
 
   This is a variant of strtok() that is multithread-safe and supports
38
 
   empty fields.
39
 
 
40
 
   Caveat: It modifies the original string.
41
 
   Caveat: These functions cannot be used on constant strings.
42
 
   Caveat: The identity of the delimiting character is lost.
43
 
   Caveat: It doesn't work with multibyte strings unless all of the delimiter
44
 
           characters are ASCII characters < 0x30.
45
 
 
46
 
   See also strtok_r().  */
47
 
 
48
 
extern char *strsep (char **stringp, const char *delim);
49
 
 
50
 
#endif
51
 
 
52
 
#endif /* GNULIB_STRSEP_H_ */