synchronized void putByte(long offset, byte b) throws IndexOutOfBoundsException, IOException {

		checkValid();

		if (offset < 0 || offset >= size) {
			throw new IndexOutOfBoundsException();
		}

		// The max buffer size will be the size of the first buffer. (If more than
		// one buffer exists, then the first buffer will be the true max size.  If only one buffer,
		// then its actual size can be used as the max size and it won't matter.)
		int maxBufferSize = layeredBuffers[0].length();

		int dbBufferIndex = (int) (offset / maxBufferSize);
		int localOffset = (int) (offset % maxBufferSize);
		layeredBuffers[dbBufferIndex].putByte(localOffset, b);
	}
Changes the byte at the given offset to the given value. Note, the 
original byte can still be accessed via {@link #getOriginalByte(long)}
If the byte is changed more than once, only the original value is preserved.

@param offset the offset into the file bytes.
@param b the new byte value;
@throws IndexOutOfBoundsException if invalid offset is specified
@throws IOException if the write to the database fails.
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/mem/FileBytes.java