 
                 # Get the requested start and end
                 # Force into integers
-                requestStart    = rangeVals[1] - 0 or undefined
-                requestEnd      = rangeVals[2] - 0 or undefined
+                requestStart    = if rangeVals[1]? then rangeVals[1] - 0 else undefined
+                requestEnd      = if rangeVals[2]? then rangeVals[2] - 0 else undefined
 
                 if requestStart && requestEnd && (requestStart > requestEnd)
                     res.writeHead 416, "Content-type":"text/html"


                    return false

                if requestStart && !requestEnd
                    rangeEnd    = fend

                else if requestEnd && !requestStart
                    rangeStart  = fend - requestEnd
                    rangeEnd    = fend


                    rangeEnd    = requestEnd

                length = (rangeEnd - rangeStart) + 1

            # send out headers
            headers =
