* This file is part of the FreeRTOS+UDP distribution. The FreeRTOS+UDP license\r
* terms are different to the FreeRTOS license terms.\r
*\r
- * FreeRTOS+UDP uses a dual license model that allows the software to be used \r
- * under a standard GPL open source license, or a commercial license. The \r
- * standard GPL license (unlike the modified GPL license under which FreeRTOS \r
- * itself is distributed) requires that all software statically linked with \r
- * FreeRTOS+UDP is also distributed under the same GPL V2 license terms. \r
+ * FreeRTOS+UDP uses a dual license model that allows the software to be used\r
+ * under a standard GPL open source license, or a commercial license. The\r
+ * standard GPL license (unlike the modified GPL license under which FreeRTOS\r
+ * itself is distributed) requires that all software statically linked with\r
+ * FreeRTOS+UDP is also distributed under the same GPL V2 license terms.\r
* Details of both license options follow:\r
*\r
* - Open source licensing -\r
*\r
* - Commercial licensing -\r
* Businesses and individuals that for commercial or other reasons cannot comply\r
- * with the terms of the GPL V2 license must obtain a commercial license before \r
- * incorporating FreeRTOS+UDP into proprietary software for distribution in any \r
- * form. Commercial licenses can be purchased from http://shop.freertos.org/udp \r
+ * with the terms of the GPL V2 license must obtain a commercial license before\r
+ * incorporating FreeRTOS+UDP into proprietary software for distribution in any\r
+ * form. Commercial licenses can be purchased from http://shop.freertos.org/udp\r
* and do not require any source files to be changed.\r
*\r
* FreeRTOS+UDP is distributed in the hope that it will be useful. You cannot\r
/*\r
* Create the DNS message in the zero copy buffer passed in the first parameter.\r
*/\r
-static size_t prvCreateDNSMessage( uint8_t *pucUDPPayloadBuffer, const uint8_t *pcHostName, uint16_t usIdentifier );\r
+static size_t prvCreateDNSMessage( uint8_t *pucUDPPayloadBuffer, const char *pcHostName, uint16_t usIdentifier );\r
\r
/*\r
* Simple routine that jumps over the NAME field of a resource record.\r
\r
/*-----------------------------------------------------------*/\r
\r
-uint32_t FreeRTOS_gethostbyname( const uint8_t *pcHostName )\r
+uint32_t FreeRTOS_gethostbyname( const char *pcHostName )\r
{\r
static uint16_t usIdentifier = 0;\r
struct freertos_sockaddr xAddress;\r
portBASE_TYPE xAttempt;\r
int32_t lBytes;\r
size_t xPayloadLength;\r
-const size_t xExpectedPayloadLength = sizeof( xDNSMessage_t ) + strlen( ( const char * const ) pcHostName ) + sizeof( uint16_t ) + sizeof( uint16_t ) + 2; /* Two for the count of characters in the first subdomain part, and the string end byte */\r
+const size_t xExpectedPayloadLength = sizeof( xDNSMessage_t ) + strlen( pcHostName ) + sizeof( uint16_t ) + sizeof( uint16_t ) + 2; /* Two for the count of characters in the first subdomain part, and the string end byte */\r
\r
if( xDNSSocket == NULL )\r
{\r
}\r
/*-----------------------------------------------------------*/\r
\r
-static size_t prvCreateDNSMessage( uint8_t *pucUDPPayloadBuffer, const uint8_t *pcHostName, uint16_t usIdentifier )\r
+static size_t prvCreateDNSMessage( uint8_t *pucUDPPayloadBuffer, const char *pcHostName, uint16_t usIdentifier )\r
{\r
xDNSMessage_t *pxDNSMessageHeader;\r
uint8_t *pucStart, *pucByte;\r
pucByte = pucStart + 1;\r
\r
/* Copy in the host name. */\r
- strcpy( ( char * ) pucByte, ( const char * ) pcHostName );\r
+ strcpy( ( char * ) pucByte, pcHostName );\r
\r
/* Mark the end of the string. */\r
- pucByte += strlen( ( const char * ) pcHostName );\r
+ pucByte += strlen( pcHostName );\r
*pucByte = 0x00;\r
\r
/* Walk the string to replace the '.' characters with byte counts.\r