Reduce zmodem debugging
This commit is contained in:
@@ -17,6 +17,9 @@ class Item
|
||||
{
|
||||
private const LOGKEY = 'I--';
|
||||
|
||||
// For deep debugging
|
||||
protected bool $DEBUG = FALSE;
|
||||
|
||||
protected const IS_PKT = (1<<1);
|
||||
protected const IS_ARC = (1<<2);
|
||||
protected const IS_FILE = (1<<3);
|
||||
|
@@ -273,7 +273,9 @@ final class Send extends Item
|
||||
}
|
||||
|
||||
$this->file_pos += strlen($data);
|
||||
Log::debug(sprintf('%s: - Read [%d] bytes, file pos now [%d]',self::LOGKEY,strlen($data),$this->file_pos));
|
||||
|
||||
if ($this->DEBUG)
|
||||
Log::debug(sprintf('%s: - Read [%d] bytes, file pos now [%d]',self::LOGKEY,strlen($data),$this->file_pos));
|
||||
|
||||
if ($data === FALSE)
|
||||
throw new UnreadableFileEncountered('Error reading file: '.$this->sending->file_name);
|
||||
|
Reference in New Issue
Block a user