wp/wp-includes/class-wp-http-encoding.php
changeset 19 3d72ae0968f4
parent 18 be944660c56a
child 21 48c4eec2b7e6
--- a/wp/wp-includes/class-wp-http-encoding.php	Wed Sep 21 18:19:35 2022 +0200
+++ b/wp/wp-includes/class-wp-http-encoding.php	Tue Sep 27 16:37:53 2022 +0200
@@ -88,7 +88,7 @@
 	 *
 	 * Warning: Magic numbers within. Due to the potential different formats that the compressed
 	 * data may be returned in, some "magic offsets" are needed to ensure proper decompression
-	 * takes place. For a simple progmatic way to determine the magic offset in use, see:
+	 * takes place. For a simple pragmatic way to determine the magic offset in use, see:
 	 * https://core.trac.wordpress.org/ticket/18273
 	 *
 	 * @since 2.8.1
@@ -97,38 +97,38 @@
 	 * @link https://www.php.net/manual/en/function.gzinflate.php#70875
 	 * @link https://www.php.net/manual/en/function.gzinflate.php#77336
 	 *
-	 * @param string $gzData String to decompress.
+	 * @param string $gz_data String to decompress.
 	 * @return string|false Decompressed string on success, false on failure.
 	 */
-	public static function compatible_gzinflate( $gzData ) {
+	public static function compatible_gzinflate( $gz_data ) {
 
 		// Compressed data might contain a full header, if so strip it for gzinflate().
-		if ( "\x1f\x8b\x08" === substr( $gzData, 0, 3 ) ) {
+		if ( "\x1f\x8b\x08" === substr( $gz_data, 0, 3 ) ) {
 			$i   = 10;
-			$flg = ord( substr( $gzData, 3, 1 ) );
+			$flg = ord( substr( $gz_data, 3, 1 ) );
 			if ( $flg > 0 ) {
 				if ( $flg & 4 ) {
-					list($xlen) = unpack( 'v', substr( $gzData, $i, 2 ) );
+					list($xlen) = unpack( 'v', substr( $gz_data, $i, 2 ) );
 					$i          = $i + 2 + $xlen;
 				}
 				if ( $flg & 8 ) {
-					$i = strpos( $gzData, "\0", $i ) + 1;
+					$i = strpos( $gz_data, "\0", $i ) + 1;
 				}
 				if ( $flg & 16 ) {
-					$i = strpos( $gzData, "\0", $i ) + 1;
+					$i = strpos( $gz_data, "\0", $i ) + 1;
 				}
 				if ( $flg & 2 ) {
 					$i = $i + 2;
 				}
 			}
-			$decompressed = @gzinflate( substr( $gzData, $i, -8 ) );
+			$decompressed = @gzinflate( substr( $gz_data, $i, -8 ) );
 			if ( false !== $decompressed ) {
 				return $decompressed;
 			}
 		}
 
 		// Compressed data from java.util.zip.Deflater amongst others.
-		$decompressed = @gzinflate( substr( $gzData, 2 ) );
+		$decompressed = @gzinflate( substr( $gz_data, 2 ) );
 		if ( false !== $decompressed ) {
 			return $decompressed;
 		}