@Override
		public int read() throws IOException {
			if (pointer < segmentLength.value()) {
				if (bufferpointer < buffer.length) {
					pointer++;
					return buffer[bufferpointer++] & 0xff;
				}
				try {
					establishNextBuffer();
					pointer++;
					return buffer[bufferpointer++] & 0xff;		// Don't allow sign-extension to happen
				}
				catch (IOException e) {
					log.appendMsg(e.getMessage());
				}
			}
			return -1;
		}
Fill the next buffer of bytes being provided by this stream.
@throws IOException for problems with the file image reader
Ghidra/Features/Base/src/main/java/ghidra/app/util/bin/format/omf/omf/OmfSegmentHeader.java