~ubuntu-branches/ubuntu/vivid/curl/vivid

« back to all changes in this revision

Viewing changes to lib/dict.c

  • Committer: Bazaar Package Importer
  • Author(s): Andreas Schuldei
  • Date: 2009-04-02 23:35:45 UTC
  • mto: (1.2.1 upstream) (3.2.3 sid)
  • mto: This revision was merged to the branch mainline in revision 38.
  • Revision ID: james.westby@ubuntu.com-20090402233545-geixkwhe3izccjt7
Tags: upstream-7.19.4
ImportĀ upstreamĀ versionĀ 7.19.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
 *                            | (__| |_| |  _ <| |___
6
6
 *                             \___|\___/|_| \_\_____|
7
7
 *
8
 
 * Copyright (C) 1998 - 2007, Daniel Stenberg, <daniel@haxx.se>, et al.
 
8
 * Copyright (C) 1998 - 2008, Daniel Stenberg, <daniel@haxx.se>, et al.
9
9
 *
10
10
 * This software is licensed as described in the file COPYING, which
11
11
 * you should have received as part of this distribution. The terms
18
18
 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
19
19
 * KIND, either express or implied.
20
20
 *
21
 
 * $Id: dict.c,v 1.55 2007-12-08 22:50:55 bagder Exp $
 
21
 * $Id: dict.c,v 1.60 2008-12-19 21:14:52 bagder Exp $
22
22
 ***************************************************************************/
23
23
 
24
24
#include "setup.h"
53
53
#ifdef HAVE_NET_IF_H
54
54
#include <net/if.h>
55
55
#endif
 
56
#ifdef HAVE_SYS_IOCTL_H
56
57
#include <sys/ioctl.h>
57
 
#include <signal.h>
 
58
#endif
58
59
 
59
60
#ifdef HAVE_SYS_PARAM_H
60
61
#include <sys/param.h>
75
76
#include "progress.h"
76
77
#include "strequal.h"
77
78
#include "dict.h"
 
79
#include "rawstr.h"
78
80
 
79
81
#define _MPRINTF_REPLACE /* use our functions only */
80
82
#include <curl/mprintf.h>
104
106
  ZERO_NULL,                            /* doing */
105
107
  ZERO_NULL,                            /* proto_getsock */
106
108
  ZERO_NULL,                            /* doing_getsock */
 
109
  ZERO_NULL,                            /* perform_getsock */
107
110
  ZERO_NULL,                            /* disconnect */
108
111
  PORT_DICT,                            /* defport */
109
112
  PROT_DICT                             /* protocol */
164
167
    /* AUTH is missing */
165
168
  }
166
169
 
167
 
  if(strnequal(path, DICT_MATCH, sizeof(DICT_MATCH)-1) ||
168
 
      strnequal(path, DICT_MATCH2, sizeof(DICT_MATCH2)-1) ||
169
 
      strnequal(path, DICT_MATCH3, sizeof(DICT_MATCH3)-1)) {
 
170
  if(Curl_raw_nequal(path, DICT_MATCH, sizeof(DICT_MATCH)-1) ||
 
171
      Curl_raw_nequal(path, DICT_MATCH2, sizeof(DICT_MATCH2)-1) ||
 
172
      Curl_raw_nequal(path, DICT_MATCH3, sizeof(DICT_MATCH3)-1)) {
170
173
 
171
174
    word = strchr(path, ':');
172
175
    if(word) {
223
226
    if(result)
224
227
      return result;
225
228
  }
226
 
  else if(strnequal(path, DICT_DEFINE, sizeof(DICT_DEFINE)-1) ||
227
 
           strnequal(path, DICT_DEFINE2, sizeof(DICT_DEFINE2)-1) ||
228
 
           strnequal(path, DICT_DEFINE3, sizeof(DICT_DEFINE3)-1)) {
 
229
  else if(Curl_raw_nequal(path, DICT_DEFINE, sizeof(DICT_DEFINE)-1) ||
 
230
           Curl_raw_nequal(path, DICT_DEFINE2, sizeof(DICT_DEFINE2)-1) ||
 
231
           Curl_raw_nequal(path, DICT_DEFINE3, sizeof(DICT_DEFINE3)-1)) {
229
232
 
230
233
    word = strchr(path, ':');
231
234
    if(word) {