~ubuntu-branches/ubuntu/lucid/wget/lucid-security

« back to all changes in this revision

Viewing changes to src/spider.c

  • Committer: Bazaar Package Importer
  • Author(s): Marc Deslauriers
  • Date: 2009-12-12 08:15:59 UTC
  • mfrom: (2.1.5 squeeze)
  • Revision ID: james.westby@ubuntu.com-20091212081559-mvccl4kzdqb138y3
Tags: 1.12-1.1ubuntu1
* Merge from debian testing, remaining changes:
  - Add wget-udeb to ship wget.gnu as alternative to busybox wget
    implementation.
* Keep build dependencies in main:
  - debian/control: remove info2man build-dep
  - debian/patches/00list: disable wget-infopod_generated_manpage.dpatch

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* Keep track of visited URLs in spider mode.
2
 
   Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc.
 
2
   Copyright (C) 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
3
3
 
4
4
This file is part of GNU Wget.
5
5
 
27
27
shall include the source code for the parts of OpenSSL used as well
28
28
as that of the covered work.  */
29
29
 
30
 
#include <config.h>
 
30
#include "wget.h"
31
31
 
32
32
#include <stdio.h>
33
33
#include <errno.h>
34
34
#include <assert.h>
35
35
 
36
 
#include "wget.h"
37
36
#include "spider.h"
38
37
#include "url.h"
39
38
#include "utils.h"
69
68
{
70
69
  hash_table_iterator iter;
71
70
  int num_elems;
72
 
  
73
 
  if (!nonexisting_urls_set) 
 
71
 
 
72
  if (!nonexisting_urls_set)
74
73
    {
75
74
      logprintf (LOG_NOTQUIET, _("Found no broken links.\n\n"));
76
75
      return;
77
76
    }
78
 
  
 
77
 
79
78
  num_elems = hash_table_count (nonexisting_urls_set);
80
79
  assert (num_elems > 0);
81
80
 
82
81
  logprintf (LOG_NOTQUIET, ngettext("Found %d broken link.\n\n",
83
82
                                    "Found %d broken links.\n\n", num_elems),
84
83
             num_elems);
85
 
  
 
84
 
86
85
  for (hash_table_iterate (nonexisting_urls_set, &iter);
87
86
       hash_table_iter_next (&iter); )
88
87
    {
89
 
      struct url_list *list;
 
88
      /* Struct url_list *list; */
90
89
      const char *url = (const char *) iter.key;
91
 
          
 
90
 
92
91
      logprintf (LOG_NOTQUIET, _("%s\n"), url);
93
92
    }
94
93
  logputs (LOG_NOTQUIET, "\n");