bugGNU Wget - Bugs: bug #61140, wget 1.21.2 breaks metalink...


bug #61140: wget 1.21.2 breaks metalink support on 32-bit x86

Submitter:  Jan Palus <jpalus>
Submitted:  Fri 10 Sep 2021 11:41:56 PM UTC
Category:  Build/Install Severity:  3 - Normal
Priority:  5 - Normal Status:  Need Info
Privacy:  Public Assigned to:  None
Originator Name:  Open/Closed:  Closed
Release:  None Operating System:  GNU/Linux
Reproducibility:  Every Time Fixed Release:  None
Planned Release:  None Regression:  Yes
Work Required:  None Patch Included:  No
* Mandatory Fields

Add a New Comment (Rich Markup)

Comment Type & Canned Response:


Thu 14 Oct 2021 02:09:09 PM UTC, comment #5: 

Shoot, I don't know how I missed this option. Solved, thanks Jan!!

Michal Ruprich <formaiko>
Thu 14 Oct 2021 12:09:42 PM UTC, comment #4: 

Try building wget with '--disable-year2038' passed to configure. If it helps then that's the same issue.

Jan Palus <jpalus>
Thu 14 Oct 2021 11:57:24 AM UTC, comment #3: 

Hi Jan,

I was trying to build the new version and hit a problem with failing tests for metalink. Is it possible that it is related? What was the thing that broke for metalink in your case? Was it the build or the tests? I see metalink tests failing only on 32bit arch so I thought it might be related but I was trying to figure out what is going on for some time now and got nowhere.

The result of the metalink tests on 32bit is always the same(example is the Test-metalink-http-xml.py test):

Retrieving from Metalink 'main.metalink.meta#2'
Error: Expected file main.metalink.meta#2.#1 not found..
Traceback (most recent call last):
  File "/root/rpmbuild/BUILD/wget-1.21.2/testenv/./Test-metalink-http-xml.py", line 270, in <module>
    err = http_test.begin ()
  File "/root/rpmbuild/BUILD/wget-1.21.2/testenv/test/http_test.py", line 41, in begin
  File "/root/rpmbuild/BUILD/wget-1.21.2/testenv/test/base_test.py", line 198, in do_test
  File "/root/rpmbuild/BUILD/wget-1.21.2/testenv/test/base_test.py", line 217, in post_hook_call
    self.hook_call(self.post_configs, 'Post Test Function')
  File "/root/rpmbuild/BUILD/wget-1.21.2/testenv/test/base_test.py", line 207, in hook_call
  File "/root/rpmbuild/BUILD/wget-1.21.2/testenv/conf/expected_files.py", line 55, in _call_
    raise TestFailed('Expected file %s not found.' % file.name)
exc.test_failed.TestFailed: Expected file main.metalink.meta#2.#1 not found.

The main.metalink.meta#2 is downloaded but it stops there. Both the passing tests and failing tests look similar and I was not able to figure out why this breaks. Is it possible that this could be related?

Thanks for any tips I am really out of clues here.
Michal Ruprich

Michal Ruprich <formaiko>
Mon 13 Sep 2021 10:50:53 AM UTC, comment #2: 

Yes I did disable it ultimately (after lengthy debugging of why tests fail) but in my opinion packages should only add support for y2038, in the sense they're working fine when time_t is 64bit on 32bit arch, but they should not enable/disable it voluntarily. I would consider it packager maintainer's job and mechanism should be global through global compiler flags.

To be clear this issue is only to raise awareness that it might cause problems for distros without y2038 enabled yet. Strictly speaking I don't see any bug here.

Jan Palus <jpalus>
Sat 11 Sep 2021 03:32:45 PM UTC, comment #1: 

What distro are you on?

This is something the distro maintainers should handle. Unfortunately, having ABI compatibility with two different ABI's is not feasible and switching off y2038 would not be a smart thing to do. It should be disabled at compile time by the distro maintainer. Or at least make sure that everything in the repositories is consistent.

Darshit Shah <darnir>
Project Administrator
Fri 10 Sep 2021 11:41:56 PM UTC, original submission:  

Just a note that tests related to metalink started to fail on 32-bit x86 in default setup. That's because y2038 is enabled by default resulting in ABI incompatibility between the two if libmetalink was not compiled with y2038. metalink_t includes two time_t fields before crucial "files" field and difference in time_t size results in broken access to "files".

I would say it should be up to linux distribution to enable y2038 globally instead of per package toggles.

Jan Palus <jpalus>


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by formaiko (Posted a comment)
  • -email is unavailable- added by darnir (Posted a comment)
  • -email is unavailable- added by jpalus (Submitted the item)




    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-10-08 darnir Open/ClosedOpen Closed
    2021-09-11 darnir StatusNone Need Info

    Back to the top

    Powered by Savane 3.9