Compare commits

..

10 Commits

Author SHA1 Message Date
Xavier Roche
46b7b8ed3f debian: override source-is-missing for upstream HTML docs
The bundled html/ and templates/ pages are the genuine upstream
documentation from the httrack.com website. lintian's long-line
heuristic flags them as missing source; they are the actual source.
2026-06-12 21:44:44 +02:00
Xavier Roche
2f40122bec debian: fix assorted lintian tags
- webhttrack: depend firmly on sensible-utils (it calls sensible-browser),
  drop the missing-depends-on-sensible-utils override.
- copyright: point to /usr/share/common-licenses/GPL-3, not the GPL symlink.
- watch: use https and version=4.
- control: add Rules-Requires-Root: no and Vcs-Browser.
- strip trailing whitespace in control, rules and changelog.
2026-06-12 21:27:11 +02:00
Xavier Roche
26b62369c5 build: link libhtsjava and libtest examples against libc
libhtsjava and the libtest callback examples reach libc only through
libhttrack, so the linker drops the direct libc edge from DT_NEEDED.
lintian flags this as library-not-linked-against-libc. Force libc to be
recorded as a dependency and drop the now-redundant override.
2026-06-12 21:23:29 +02:00
Xavier Roche
b21f85c53f Merge pull request #317 from xroche/fix/cookie-cmp-loop
Fix never-matching wildcard cookie domain comparison
2026-06-09 20:12:01 +02:00
Xavier Roche
0a20aa8522 Fix never-matching wildcard cookie domain comparison
cookie_cmp_wildcard_domain used an unsigned loop counter, so i >= 0 was always
true (infinite loop and out-of-bounds reads) and an empty domain underflowed
l - 1. Use a signed counter. Found and fixed by greenrd in #172. closes #171
2026-06-09 20:09:23 +02:00
Xavier Roche
abd19b8cfa Merge pull request #316 from xroche/chore/changelog-news-symlink
build: symlink ChangeLog and NEWS to history.txt
2026-06-08 20:40:51 +02:00
Xavier Roche
4797749d4d build: symlink ChangeLog and NEWS to history.txt
They were empty automake stubs (GNU strictness requires the files to exist).
Pointing them at history.txt satisfies automake, drops the confusing empty
files, and ships a real changelog in the dist tarball without duplicating
content in git.
2026-06-08 20:40:27 +02:00
Xavier Roche
566b9d5008 Merge pull request #315 from xroche/docs/readme-badges
docs: add CI and license badges to README.md
2026-06-08 20:22:21 +02:00
Xavier Roche
8b6bc1d0ed docs: add CI and license badges to README.md 2026-06-08 20:21:52 +02:00
Xavier Roche
e4fc8ca26f Merge pull request #314 from xroche/ci/github-actions
ci: add GitHub Actions build/test matrix and shell lint
2026-06-08 20:19:11 +02:00
14 changed files with 33 additions and 17 deletions

View File

1
ChangeLog Symbolic link
View File

@@ -0,0 +1 @@
history.txt

0
NEWS
View File

1
NEWS Symbolic link
View File

@@ -0,0 +1 @@
history.txt

View File

@@ -1,5 +1,8 @@
# HTTrack Website Copier - Development Repository
[![CI](https://github.com/xroche/httrack/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/xroche/httrack/actions/workflows/ci.yml)
[![License](https://img.shields.io/github/license/xroche/httrack)](COPYING)
## About
_Copy websites to your computer (Offline browser)_

3
debian/changelog vendored
View File

@@ -934,7 +934,7 @@ httrack (3.39.6-1) unstable; urgency=low
httrack (3.39.5-1) unstable; urgency=low
* Updated to 3.39.5 (3.40-alpha-5)
* Updated to 3.39.5 (3.40-alpha-5)
-- Xavier Roche <xavier@debian.org> Fri, 29 Jul 2005 20:57:44 +0200
@@ -1616,4 +1616,3 @@ httrack (3.22-1) unstable; urgency=low
* Initial Release.
-- Xavier Roche <xavier@debian.org> Fri, 27 Sep 2002 16:42:25 +0200

6
debian/control vendored
View File

@@ -4,8 +4,10 @@ Priority: optional
Maintainer: Xavier Roche <roche@httrack.com>
Standards-Version: 4.7.0
Build-Depends: debhelper-compat (= 13), autoconf, autoconf-archive, automake, libtool, zlib1g-dev, libssl-dev
Rules-Requires-Root: no
Homepage: http://www.httrack.com
Vcs-Git: https://github.com/xroche/httrack.git
Vcs-Browser: https://github.com/xroche/httrack
Package: httrack
Architecture: any
@@ -23,12 +25,12 @@ Description: Copy websites to your computer (Offline browser)
browse the site from link to link, as if you were viewing it online.
HTTrack can also update an existing mirrored site, and resume
interrupted downloads. HTTrack is fully configurable, and has an
integrated help system.
integrated help system.
Package: webhttrack
Architecture: any
Multi-Arch: foreign
Depends: ${misc:Depends}, ${shlibs:Depends}, webhttrack-common, iceape-browser | iceweasel | icecat | mozilla | firefox | mozilla-firefox | www-browser | sensible-utils
Depends: ${misc:Depends}, ${shlibs:Depends}, webhttrack-common, sensible-utils, iceape-browser | iceweasel | icecat | mozilla | firefox | mozilla-firefox | www-browser
Replaces: webhttrack-common (<< 3.43.9-2)
Breaks: webhttrack-common (<< 3.43.9-2)
Suggests: httrack, httrack-doc

2
debian/copyright vendored
View File

@@ -13,7 +13,7 @@ the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
On Debian systems, the complete text of the GNU General Public
License can be found in /usr/share/common-licenses/GPL file.
License version 3 can be found in /usr/share/common-licenses/GPL-3 file.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of

View File

@@ -1,5 +1,4 @@
libhttrack-dev: breakout-link *
libhttrack-dev: hardening-no-fortify-functions usr/lib/x86_64-linux-gnu/httrack/libtest/*
libhttrack-dev: library-not-linked-against-libc usr/lib/*/httrack/libtest/*
libhttrack-dev: package-contains-documentation-outside-usr-share-doc usr/share/httrack/libtest/readme.txt
libhttrack-dev: package-name-defined-in-config-h usr/include/httrack/config.h

2
debian/rules vendored
View File

@@ -44,7 +44,7 @@ build-indep:
build-arch: build-stamp
build-stamp: configure-stamp
build-stamp: configure-stamp
dh_testdir
dh_auto_build
dh_auto_test

View File

@@ -1,2 +1,8 @@
httrack source: changelog-should-mention-nmu
httrack source: source-nmu-has-incorrect-version-number
# The bundled HTML pages are the genuine upstream documentation taken from
# the httrack.com website. lintian's long-line heuristic mistakes them for
# minified or generated content, but they are the actual source.
httrack source: source-is-missing [html/*]
httrack source: source-is-missing [templates/*]

9
debian/watch vendored
View File

@@ -1,7 +1,6 @@
# format version number, currently 3; this line is compulsory!
version=3
# format version number; this line is compulsory!
version=4
# main httrack.com download page ; fetch the mirror version number
http://www.httrack.com/page/2/en/index.html\
.*/httrack-([\d\.]+).tar.gz
https://www.httrack.com/page/2/en/index.html \
.*/httrack-([\d\.]+)\.tar\.gz

View File

@@ -1 +0,0 @@
webhttrack: missing-depends-on-sensible-utils sensible-browser usr/bin/webhttrack

View File

@@ -14,9 +14,13 @@ AM_CPPFLAGS = \
-DLIBDIR=\""$(libdir)"\"
AM_CPPFLAGS += -I../src
# The callback examples reference libc only through libhttrack, so the direct
# libc edge gets dropped from DT_NEEDED (library-not-linked-against-libc).
# Force libc to be recorded as a dependency.
AM_LDFLAGS = \
@DEFAULT_LDFLAGS@ \
-L../src
-L../src \
-Wl,--push-state,--no-as-needed,-lc,--pop-state
# Examples
libbaselinks_la_SOURCES = callbacks-example-baselinks.c

View File

@@ -83,7 +83,10 @@ libhttrack_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(VERSION_INFO)
libhtsjava_la_SOURCES = htsjava.c htsjava.h
libhtsjava_la_LIBADD = $(THREADS_LIBS) $(DL_LIBS) libhttrack.la
libhtsjava_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(VERSION_INFO)
# This thin JNI wrapper reaches libc only through libhttrack, so the direct
# libc edge is dropped from DT_NEEDED (library-not-linked-against-libc). Force
# libc to be recorded as a dependency.
libhtsjava_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(VERSION_INFO) -Wl,--push-state,--no-as-needed,-lc,--pop-state
EXTRA_DIST = httrack.h webhttrack \
coucal/murmurhash3.h.diff \

View File

@@ -133,8 +133,8 @@ static int cookie_cmp_wildcard_domain(const char *chk_dom, const char *domain) {
const size_t n = strlen(chk_dom);
const size_t m = strlen(domain);
const size_t l = n < m ? n : m;
size_t i;
for (i = l - 1; i >= 0; i--) {
int i;
for (i = (int) l - 1; i >= 0; i--) {
if (chk_dom[n - i - 1] != domain[m - i - 1]) {
return 1;
}