错误:test.c:22: error: conflicting types for 'urlencode'test.c:18: error: previous implicit declaration of 'urlencode' was here
原来是因为没有先做函数声明,而函数位于main()之后。在main函数前声明了函数原型后,一切ok.