--- a/upnpsoap.c
+++ b/upnpsoap.c
@@ -46,6 +46,8 @@
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGE.
  */
+#include "config.h"
+
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -59,7 +61,6 @@
 #include <netdb.h>
 #include <ctype.h>
 
-#include "config.h"
 #include "upnpglobalvars.h"
 #include "utils.h"
 #include "upnphttp.h"