fbdtemme / torrenttools

Commandline tool for inspecting, creating and editing BitTorrent metafiles.
MIT License
200 stars 15 forks source link

torrenttools info: segfault on large torrent files #52

Open milahu opened 3 months ago

milahu commented 3 months ago
$ curl -s -o test.torrent https://annas-archive.gs/dyn/small_file/torrents/managed_by_aa/annas_archive_data__aacid/annas_archive_data__aacid__upload_files_trantor__20240510T044430Z--20240510T044431Z.torrent

$ du -b test.torrent
2943036 test.torrent

$ du -h test.torrent
2.9M    test.torrent

$ time torrenttools show files test.torrent | wc -l
30000
real    0m0.299s
user    0m0.197s
sys     0m0.106s

$ $(which time) -v torrenttools info test.torrent
Segmentation fault (core dumped)
Command terminated by signal 11
        Command being timed: "torrenttools info test.torrent"
        User time (seconds): 0.42
        System time (seconds): 16.89
        Percent of CPU this job got: 15%
        Elapsed (wall clock) time (h:mm:ss or m:ss): 1:51.79
        Average shared text size (kbytes): 0
        Average unshared data size (kbytes): 0
        Average stack size (kbytes): 0
        Average total size (kbytes): 0
        Maximum resident set size (kbytes): 41596
        Average resident set size (kbytes): 0
        Major (requiring I/O) page faults: 0
        Minor (reclaiming a frame) page faults: 13149
        Voluntary context switches: 20292
        Involuntary context switches: 31216
        Swaps: 0
        File system inputs: 5768
        File system outputs: 0
        Socket messages sent: 0
        Socket messages received: 0
        Signals delivered: 0
        Page size (bytes): 4096
        Exit status: 0