loganer<p><a href="https://mastodon.social/tags/C" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>C</span></a> <a href="https://mastodon.social/tags/Programming" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Programming</span></a> <a href="https://mastodon.social/tags/Networking" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Networking</span></a> <a href="https://mastodon.social/tags/Inquiry" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Inquiry</span></a> </p><p>to send a file over a socket connection do I just read the file from the disk and send them as raw bytes or is there something special i need to do?</p><p>for example, if I have a TestImage.png in my 'web root' directory and a browser request the /TestImage.png , do I just read the file byte for byte into an array and then just send that to be browser?</p>