Skip to content

Commit bfd8514

Browse files
Remove -Wno-pedantic build requirement for FreeRTOS_Sockets.c (FreeRTOS#1146)
* Remove non pedantic build check requirement for sockets.c * Fix formatting
1 parent a4295d3 commit bfd8514

File tree

10 files changed

+50
-7
lines changed

10 files changed

+50
-7
lines changed

source/CMakeLists.txt

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -92,11 +92,6 @@ target_include_directories( freertos_plus_tcp
9292
include
9393
)
9494

95-
# Suppressions required to build clean with GCC
96-
if(CMAKE_C_COMPILER_ID STREQUAL GNU)
97-
set_source_files_properties(FreeRTOS_Sockets.c PROPERTIES COMPILE_FLAGS -Wno-pedantic)
98-
endif()
99-
10095
target_link_libraries( freertos_plus_tcp
10196
PUBLIC
10297
freertos_config

source/FreeRTOS_Sockets.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3779,8 +3779,6 @@ void vSocketWakeUpUser( FreeRTOS_Socket_t * pxSocket )
37793779
BaseType_t xResult = -pdFREERTOS_ERRNO_EINVAL;
37803780
TimeOut_t xTimeOut;
37813781

3782-
( void ) xAddressLength;
3783-
37843782
#if ( ipconfigIPv4_BACKWARD_COMPATIBLE == 1 )
37853783
struct freertos_sockaddr xTempAddress;
37863784

@@ -3795,6 +3793,8 @@ void vSocketWakeUpUser( FreeRTOS_Socket_t * pxSocket )
37953793
}
37963794
#endif /* ( ipconfigIPv4_BACKWARD_COMPATIBLE == 1 ) */
37973795

3796+
( void ) xAddressLength;
3797+
37983798
xResult = prvTCPConnectStart( pxSocket, pxAddress );
37993799

38003800
if( xResult == 0 )

test/build-combination/AllDisable/FreeRTOSIPConfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -294,4 +294,10 @@
294294

295295
#define portINLINE __inline
296296

297+
#define ipconfigISO_STRICTNESS_VIOLATION_START \
298+
_Pragma("GCC diagnostic push") \
299+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
300+
301+
#define ipconfigISO_STRICTNESS_VIOLATION_END _Pragma("GCC diagnostic pop")
302+
297303
#endif /* FREERTOS_IP_CONFIG_H */

test/build-combination/AllEnable/FreeRTOSIPConfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -322,4 +322,10 @@
322322

323323
#define portINLINE __inline
324324

325+
#define ipconfigISO_STRICTNESS_VIOLATION_START \
326+
_Pragma("GCC diagnostic push") \
327+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
328+
329+
#define ipconfigISO_STRICTNESS_VIOLATION_END _Pragma("GCC diagnostic pop")
330+
325331
#endif /* FREERTOS_IP_CONFIG_H */

test/build-combination/Enable_IPv4/FreeRTOSIPConfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,4 +325,10 @@
325325

326326
#define portINLINE __inline
327327

328+
#define ipconfigISO_STRICTNESS_VIOLATION_START \
329+
_Pragma("GCC diagnostic push") \
330+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
331+
332+
#define ipconfigISO_STRICTNESS_VIOLATION_END _Pragma("GCC diagnostic pop")
333+
328334
#endif /* FREERTOS_IP_CONFIG_H */

test/build-combination/Enable_IPv4_IPv6/FreeRTOSIPConfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,4 +325,10 @@
325325

326326
#define portINLINE __inline
327327

328+
#define ipconfigISO_STRICTNESS_VIOLATION_START \
329+
_Pragma("GCC diagnostic push") \
330+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
331+
332+
#define ipconfigISO_STRICTNESS_VIOLATION_END _Pragma("GCC diagnostic pop")
333+
328334
#endif /* FREERTOS_IP_CONFIG_H */

test/build-combination/Enable_IPv4_TCP/FreeRTOSIPConfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,4 +325,10 @@
325325

326326
#define portINLINE __inline
327327

328+
#define ipconfigISO_STRICTNESS_VIOLATION_START \
329+
_Pragma("GCC diagnostic push") \
330+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
331+
332+
#define ipconfigISO_STRICTNESS_VIOLATION_END _Pragma("GCC diagnostic pop")
333+
328334
#endif /* FREERTOS_IP_CONFIG_H */

test/build-combination/Enable_IPv6/FreeRTOSIPConfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,4 +325,10 @@
325325

326326
#define portINLINE __inline
327327

328+
#define ipconfigISO_STRICTNESS_VIOLATION_START \
329+
_Pragma("GCC diagnostic push") \
330+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
331+
332+
#define ipconfigISO_STRICTNESS_VIOLATION_END _Pragma("GCC diagnostic pop")
333+
328334
#endif /* FREERTOS_IP_CONFIG_H */

test/build-combination/Enable_IPv6_TCP/FreeRTOSIPConfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,4 +325,10 @@
325325

326326
#define portINLINE __inline
327327

328+
#define ipconfigISO_STRICTNESS_VIOLATION_START \
329+
_Pragma("GCC diagnostic push") \
330+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
331+
332+
#define ipconfigISO_STRICTNESS_VIOLATION_END _Pragma("GCC diagnostic pop")
333+
328334
#endif /* FREERTOS_IP_CONFIG_H */

test/build-combination/Header_Self_Contain/FreeRTOSIPConfig.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -321,4 +321,10 @@
321321

322322
#define portINLINE __inline
323323

324+
#define ipconfigISO_STRICTNESS_VIOLATION_START \
325+
_Pragma("GCC diagnostic push") \
326+
_Pragma("GCC diagnostic ignored \"-Wpedantic\"")
327+
328+
#define ipconfigISO_STRICTNESS_VIOLATION_END _Pragma("GCC diagnostic pop")
329+
324330
#endif /* FREERTOS_IP_CONFIG_H */

0 commit comments

Comments
 (0)