Skip to content
Snippets Groups Projects
  1. Mar 29, 2022
  2. Mar 28, 2022
  3. Mar 27, 2022
  4. Mar 25, 2022
    • Rob Swindell's avatar
      Uh, increment the pointer in globi() · 162ff6db
      Rob Swindell authored
      Fixes crash reported in #381.
      162ff6db
    • Rob Swindell's avatar
      Remove the hard-coded ".msg" extension from data/subs/*.msg display file · 6ad685d0
      Rob Swindell authored
      And data/dirs/*.msg display file. Now you can have any supported menu file in this location if you wish.
      6ad685d0
    • Rob Swindell's avatar
      Detect/display menu files, even if only a .ans version exists · c58bedb6
      Rob Swindell authored
      I'm so tired of this 30 year old frequently asked question.
      
      If a sysop really wants their Synchronet BBS to only work correctly for ANSI users, I suppose that should be their prerogative.
      
      I always felt that by not detecting/displaying menu files when the minimum set of files was not present, I was helping sysops to identify an issue with their system (which would not work correctly for non-ANSI users). *And* I always felt that having a single menu/display file that correctly supported both ANSI and non-ANSI users was a nice convenience (who really wants to maintain multiple versions of their menu files?). But I'm so tired of answering this question, I just give up.
      
      Hopefully this doesn't break anything for anyone. <shrug>
      c58bedb6
    • Rob Swindell's avatar
      Revert to *.XXcol.* being an exact column width, add *.cXX.* support · 6f4b92e7
      Rob Swindell authored
      That previous commit made all *.40col.msg files display for 80 column users. Not my intention.
      
      So revert to the previous behavior of *.XXcol.* display files. I didn't want to go renaming a bunch of menu files as a result of the previous commit and I didn't want a bunch of sysops with *.XXcol.* files to be suddenly surprised at their new BBS behavior.
      
      And introduce a new file naming convention, *.cXX.* (where XX is a MINIMUM column width). This is the same naming convention used by Mystic, which also treats it is as a minimum terminal width, not a required exact width.
      6f4b92e7
    • Rob Swindell's avatar
      Use text/menu/*.###col.* display files for even-wider terminals · 1ece52bc
      Rob Swindell authored
      e.g. display basename.132col.msg even if the terminal is 133+ columns wide.
      
      Fixes issue #380.
      1ece52bc
    • Rob Swindell's avatar
      Introduce case-insensitive version of glob(): globi() · c8dbf714
      Rob Swindell authored
      glob() is case-insensitive on Windows already, so create a work-alike for *nix.
      c8dbf714
    • Rob Swindell's avatar
      De-dupe random menu filenames by truncating at first dot, rather than last. · 1cb558da
      Rob Swindell authored
      Fix for one of the problems described in issue #380.
      
      bbs.menu("random*"); would display column-width-specific files (e.g.
      random.132col.msg) even when they weren't appropriate for the current
      user terminal width.
      
      This is fixed by truncating the filenames matching the requested pattern at
      their first-dot rather than the last.
      
      The downside is, you can't have a set of random.#.* files, where # is the
      unique part of the filename and * is the file-type extension. Just use
      the naming pattern "random-#.*" instead (or something similar) instead.
      1cb558da
  5. Mar 24, 2022
    • Rob Swindell's avatar
      DLL-export is_valid_XXXnum() functions, for web server use · 12f519f4
      Rob Swindell authored
      Fixes recently broken Win32 build
      12f519f4
    • Rob Swindell's avatar
      Fix potential seg fault when an invalid file vpath is requested · 175c4a3f
      Rob Swindell authored
      I knew I created these is_valid_*num() functions for a reason!
      175c4a3f
    • Rob Swindell's avatar
      Fix newly-introduced GCC warnings · d20ba4ab
      Rob Swindell authored
      d20ba4ab
    • Rob Swindell's avatar
      Support user credits and transfer stats > 4GB in total · 2d4ec7b8
      Rob Swindell authored
      Credits and daily free credits are accurate to the byte up to (a maximum) of 18446744073709551615 (that's 18 Exbibytes - 1).
      
      User's upload and download byte stats are now similarly extended in maximum range, but the accuracy is only "to the byte" for values less than 10,000,000,000. Beyond that value, the accuracy declines, but is generally pretty damn accurate (to 4 decimal places beyond the nearest multiple of a power of 1024), so I don't expect that to be an issue. This method of storing upload/download byte stats allowed me to use the same 10-character user record fields in the user.dat file.
      
      As a side-effect of this enhancements:
      * User and file credit values are now expressed in multiples of powers of 1024 (e.g. 4.0G rather than 4,294,967,296).
      * Free credits per day per security level has now been extended from 32 to 64-bits (to accommodate values >= 4GB).
      * adjustuserrec() now longer takes the record length since we can easily determine that automatically and don't need more "sources of truth" that can be out-of-sync (e.g. the U_CDT field length going from 10 to 20 chars with this change).
      * setting the stage for locale-dependent thousands-separators (e.g. space instead of comma) - currently still hard-coded to comma
      * more/better support for files > 4GB in size (e.g. in the batch download queue)
      * user_t ulong fields changed to either uint32_t or uint64_t - I didn't realize how many long/ulong's remained in the code (which are sometmies 32-bit, sometimes 64-bit) - ugh
      * Steve's ultoac() function renamed to u32toac() and created a C++ wrapper that still uses the old name, for homage
      2d4ec7b8
    • Rob Swindell's avatar
    • Rob Swindell's avatar
      byte-count to string routines type unsigned 64-bit int now · 3b6491c5
      Rob Swindell authored
      We don't have a use case negative byte values in strings anywhere that I can think of.
      
      Created wrapper for MSFT _ui64toa_() - unsigned 64-bit integer to ASCII string.
      
      Add Petabyte (actually, Pebibyte) support to byte_count_to_str()  and byte_estimate_to_str().
      
      Removed 'B' suffix from byte_estimate_to_str() output for values < 1024. Callers may display this returned string followed by "bytes" (or similar) and thus the 'B' suffix is redundant in that case. If the caller needs a 'B' suffix, they can detect no suffix and add it.
      3b6491c5
  6. Mar 21, 2022
    • Rob Swindell's avatar
      Fix newly introduced GCC warning · 79e05c66
      Rob Swindell authored
      warning: invalid suffix on literal; C++11 requires a space between literal and string macro
      79e05c66
    • Rob Swindell's avatar
      SMB items (messages or files) can now have 32-bit or 64-bit cost value · f1332d3e
      Rob Swindell authored
      To fully support files > 4GB in size in file bases, credit values larger than 32-bits must be supported too.
      
      There's a couple of todo comments/items included in this commit, but that's mainly to do with messages (which don't really have costs anyway).
      
      The main thing to deal with now is the fact that users can't have more than 4GB in credits in the first place! That's got to be fixed next.
      f1332d3e
    • Rob Swindell's avatar
      Fix newly-encountered GCC warning · 25d70a21
      Rob Swindell authored
      comparison of integer expressions of different signedness: ‘off_t’ {aka ‘long int’} and ‘uint64_t’ {aka ‘long unsigned int’}
      25d70a21
    • Rob Swindell's avatar
      Support files > 4MB in SMB filebase indexes · 493ea18b
      Rob Swindell authored
      Used the reserved 16-bits in the file index record to extend the supported index-file-size from 4294967295 (4GB) to 281474976710655 (281TB). I think that's big enough for the foreseeable future. :-)
      493ea18b
    • Rob Swindell's avatar
      Add options to sort directories by file size (ascending or descending) · 945a80f2
      Rob Swindell authored
      Size is indexed, so might as well sort by it. This does have an issue with files >= 4GB in length however, so I'm looking at that next.
      945a80f2
    • Rob Swindell's avatar
      3e3063a1
    • Rob Swindell's avatar
      File's meta-object's "size" and "time" properties reflect current values · bb3e6c53
      Rob Swindell authored
      Query the disk for file's current "size" and "time" values when get_list() or get() method is used with a "detail" level of >= DETAIL.NORMAL and the "check file existence" toggle option is enabled for this directory in SCFG.
      
      I pondered and contemplated whether this configuration setting should be checked/applied here or in the various JS scripts (e.g. filelist.js) and decided here was best to provide the most uniform/expected behavior, even though there is a performance impact. If a script doesn't need/use these properties, they should probably be specifying the DETAIL.MIN (minimal) detail level in their queries anyway, which will then bypass these performance-impacting disk queries.
      bb3e6c53
Loading