function Reader::resolveFourByteLittleEndian

Parameters

string $content:

int $start:

Return value

int

2 calls to Reader::resolveFourByteLittleEndian()
Manifest::fromContent in misc/typo3/phar-stream-wrapper/src/Phar/Manifest.php
Reader::resolveManifestLength in misc/typo3/phar-stream-wrapper/src/Phar/Reader.php

File

misc/typo3/phar-stream-wrapper/src/Phar/Reader.php, line 210

Class

Reader

Namespace

TYPO3\PharStreamWrapper\Phar

Code

public static function resolveFourByteLittleEndian($content, $start) {
    $payload = substr($content, $start, 4);
    if (!is_string($payload)) {
        throw new ReaderException(sprintf('Cannot resolve value at offset %d', $start), 1539614260);
    }
    $value = unpack('V', $payload);
    if (!isset($value[1])) {
        throw new ReaderException(sprintf('Cannot resolve value at offset %d', $start), 1539614261);
    }
    return $value[1];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.