I am trying to extract the query and the extension from request-line but i don't know what's the maximum length of a query and a file extension so that I can know the size of the char array to store them.
When setting the length of your char array for say query or extension, you can include a calculation or formula in between the brackets to find the size it needs to be. That's something I didn't know when I did this problem. You can even include a condition between the brackets. The easiest way to write this in one line is with the
condition ? true : false notation.