adding c server code