Make WordPress Core


Ignore:
Timestamp:
09/27/2020 04:44:01 AM (4 years ago)
Author:
SergeyBiryukov
Message:

Upgrade/Install: Update sodium_compat to v1.13.0.

This includes a few autoloader fixes and improvements.

A full list of changes in this update can be found on GitHub:
https://github.com/paragonie/sodium_compat/compare/v1.12.1...v1.13.0

See #51399.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/sodium_compat/src/Compat.php

    r46858 r49056  
    4545    public static $fastMult = false;
    4646
     47    const LIBRARY_MAJOR_VERSION = 9;
     48    const LIBRARY_MINOR_VERSION = 1;
    4749    const LIBRARY_VERSION_MAJOR = 9;
    4850    const LIBRARY_VERSION_MINOR = 1;
     
    31183120     *
    31193121     * @return int
    3120      * @psalm-suppress MixedInferredReturnType
    3121      * @psalm-suppress UndefinedFunction
    31223122     */
    31233123    public static function library_version_major()
    31243124    {
    3125         if (self::useNewSodiumAPI()) {
    3126             return sodium_library_version_major();
     3125        if (self::useNewSodiumAPI() && defined('SODIUM_LIBRARY_MAJOR_VERSION')) {
     3126            return SODIUM_LIBRARY_MAJOR_VERSION;
    31273127        }
    31283128        if (self::use_fallback('library_version_major')) {
     3129            /** @psalm-suppress UndefinedFunction */
    31293130            return (int) call_user_func('\\Sodium\\library_version_major');
    31303131        }
     
    31373138     *
    31383139     * @return int
    3139      * @psalm-suppress MixedInferredReturnType
    3140      * @psalm-suppress UndefinedFunction
    31413140     */
    31423141    public static function library_version_minor()
    31433142    {
    3144         if (self::useNewSodiumAPI()) {
    3145             return sodium_library_version_minor();
     3143        if (self::useNewSodiumAPI() && defined('SODIUM_LIBRARY_MINOR_VERSION')) {
     3144            return SODIUM_LIBRARY_MINOR_VERSION;
    31463145        }
    31473146        if (self::use_fallback('library_version_minor')) {
     3147            /** @psalm-suppress UndefinedFunction */
    31483148            return (int) call_user_func('\\Sodium\\library_version_minor');
    31493149        }
Note: See TracChangeset for help on using the changeset viewer.