From 57d5644d88df9178420cfde12d4e321304eef940 Mon Sep 17 00:00:00 2001 From: Brandon Rodriguez <brodriguez8774@gmail.com> Date: Tue, 5 Dec 2017 12:09:10 -0500 Subject: [PATCH] Organize files --- README => Documents/README | 24 +++++++++--------- .../ThreadPoolSkeleton.c | 0 client.c => Examples/client.c | 0 server.c => Examples/server.c | 0 GoodBoy.jpg => Media/GoodBoy.jpg | Bin Koala.jpg => Media/Koala.jpg | Bin TulsaQueen.mp3 => Media/TulsaQueen.mp3 | Bin 7 files changed, 12 insertions(+), 12 deletions(-) rename README => Documents/README (74%) rename ThreadPoolSkeleton.c => Examples/ThreadPoolSkeleton.c (100%) rename client.c => Examples/client.c (100%) rename server.c => Examples/server.c (100%) rename GoodBoy.jpg => Media/GoodBoy.jpg (100%) rename Koala.jpg => Media/Koala.jpg (100%) rename TulsaQueen.mp3 => Media/TulsaQueen.mp3 (100%) diff --git a/README b/Documents/README similarity index 74% rename from README rename to Documents/README index 2795fd1..f9ceece 100644 --- a/README +++ b/Documents/README @@ -1,29 +1,29 @@ Assignment 6 -- A simple server -You are to write a file server which will handle GET requests consistent with HTTP1.2 +You are to write a file server which will handle GET requests consistent with HTTP1.2 -You must do that by creating a socket that the client can use. You must handle multiple clients, each provided a thread. +You must do that by creating a socket that the client can use. You must handle multiple clients, each provided a thread. -Media types you must handle include mp3, and jpeg ... Can you extend that to video ? +Media types you must handle include mp3, and jpeg ... Can you extend that to video ? -A thread pool (skeleton of which is provided) earns bonus points. +A thread pool (skeleton of which is provided) earns bonus points. -This is due at final exam. +This is due at final exam. -I have provided three media items ... a koala, an mp3 and a cartoon that is funny. +I have provided three media items ... a koala, an mp3 and a cartoon that is funny. -This is a quick and dirty README. I have provided an example of client , server code previously but because you can't say for sure, i provide it here as well. +This is a quick and dirty README. I have provided an example of client , server code previously but because you can't say for sure, i provide it here as well. BUT THERE"S MORE ! -Also in the repo is *magic*. +Also in the repo is *magic*. -Magic.c is a piece of code which will take (as a command line argument) a path/filename and return the content type field that needs to be provided in the response header to the GET request. -Of course, you must first install magic using +Magic.c is a piece of code which will take (as a command line argument) a path/filename and return the content type field that needs to be provided in the response header to the GET request. +Of course, you must first install magic using -sudo apt-get install libmagic-dev +sudo apt-get install libmagic-dev -and then use the magic functions such as the magic cookie function magic_open() to get the mime type for usage in response header. +and then use the magic functions such as the magic cookie function magic_open() to get the mime type for usage in response header. Note that you are installing the magic library which must be loaded with -lmagic. diff --git a/ThreadPoolSkeleton.c b/Examples/ThreadPoolSkeleton.c similarity index 100% rename from ThreadPoolSkeleton.c rename to Examples/ThreadPoolSkeleton.c diff --git a/client.c b/Examples/client.c similarity index 100% rename from client.c rename to Examples/client.c diff --git a/server.c b/Examples/server.c similarity index 100% rename from server.c rename to Examples/server.c diff --git a/GoodBoy.jpg b/Media/GoodBoy.jpg similarity index 100% rename from GoodBoy.jpg rename to Media/GoodBoy.jpg diff --git a/Koala.jpg b/Media/Koala.jpg similarity index 100% rename from Koala.jpg rename to Media/Koala.jpg diff --git a/TulsaQueen.mp3 b/Media/TulsaQueen.mp3 similarity index 100% rename from TulsaQueen.mp3 rename to Media/TulsaQueen.mp3 -- GitLab