[InterNetNews/inn] ce7b67: Fix reported low water marks on empty newsgroups

Julien ÉLIE noreply at github.com
Fri Jan 20 21:02:30 UTC 2023


  Branch: refs/heads/main
  Home:   https://github.com/InterNetNews/inn
  Commit: ce7b679ece0efb06932b3ad494c8f0519dc45f38
      https://github.com/InterNetNews/inn/commit/ce7b679ece0efb06932b3ad494c8f0519dc45f38
  Author: Julien ÉLIE <Julien-Elie at users.noreply.github.com>
  Date:   2023-01-20 (Fri, 20 Jan 2023)

  Changed paths:
    M doc/pod/news.pod
    M innd/ng.c
    M nnrpd/group.c
    M nnrpd/list.c
    M storage/buffindexed/buffindexed.c
    M storage/ovdb/ovdb.c
    M storage/ovsqlite/ovsqlite-server.c
    M storage/ovsqlite/sql-main.sql
    M storage/tradindexed/tdx-group.c

  Log Message:
  -----------
  Fix reported low water marks on empty newsgroups

The reported low water mark of empty newsgroups is one more than the reported
high water mark, whereas RFC 3977 recommends that the reported high water mark
be one less than the reported low water mark.

It notably fixes an overflow for an empty newsgroups with 2^31-1 as its
highest article number:

GROUP trigofacile.test.maxartnum
211 0 2147483648 2147483647 trigofacile.test.maxartnum

Also, the reported low/high water marks will be one less than what they
currently are.  It should be best for news clients as the reported low water
mark won't increase by 1 (when advertising an empty newsgroup) before the
arrival of the next article.

/!\ Do not change the active file as innd relies on the high water mark to
assign article numbers, so we shouldn't set it to one less than its expected
value.  Comment added to mention it.

Thanks to Bo Lindbergh for the clever patch related to ovsqlite.

close #250




More information about the inn-committers mailing list