1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00

od: piggy-back style fixes

This commit is contained in:
Martine Lenders 2016-01-24 23:51:41 +01:00
parent 2173a33eab
commit f99e9e0161

View File

@ -101,15 +101,15 @@ static inline void _bytes_format(char *format, uint16_t flags)
case OD_FLAGS_BYTES_OCTAL | OD_FLAGS_LENGTH_LONG:
sprintf(format, " %%0%dlo", sizeof(long) * _OCTAL_BYTE_LENGTH);
break;
#else /* !defined(__MACH__) */
#else /* !defined(__MACH__) */
case OD_FLAGS_BYTES_OCTAL | OD_FLAGS_LENGTH_SHORT:
sprintf(format, " %lu", sizeof(short) * _OCTAL_BYTE_LENGTH);
sprintf(format, " %lu", sizeof(short) * _OCTAL_BYTE_LENGTH);
break;
case OD_FLAGS_BYTES_OCTAL | OD_FLAGS_LENGTH_LONG:
sprintf(format, " %lu", sizeof(long) * _OCTAL_BYTE_LENGTH);
break;
#endif /* !defined(__MACH__) */
#endif /* !defined(__MACH__) */
case OD_FLAGS_BYTES_INT | OD_FLAGS_LENGTH_1:
strncpy(format, " %4d", sizeof(" %4d"));
@ -135,7 +135,7 @@ static inline void _bytes_format(char *format, uint16_t flags)
case OD_FLAGS_BYTES_INT | OD_FLAGS_LENGTH_LONG:
sprintf(format, " %%%dld", sizeof(long) * _INT_BYTE_LENGTH);
break;
#else /* !defined(__MACH__) */
#else /* !defined(__MACH__) */
case OD_FLAGS_BYTES_INT | OD_FLAGS_LENGTH_SHORT:
sprintf(format, " %%%ld", sizeof(short) * _INT_BYTE_LENGTH);
break;
@ -143,7 +143,7 @@ static inline void _bytes_format(char *format, uint16_t flags)
case OD_FLAGS_BYTES_INT | OD_FLAGS_LENGTH_LONG:
sprintf(format, " %%%ld", sizeof(long) * _INT_BYTE_LENGTH);
break;
#endif /* !defined(__MACH__) */
#endif /* !defined(__MACH__) */
case OD_FLAGS_BYTES_UINT | OD_FLAGS_LENGTH_1:
strncpy(format, " %3u", sizeof(" %3u"));
@ -169,7 +169,7 @@ static inline void _bytes_format(char *format, uint16_t flags)
case OD_FLAGS_BYTES_UINT | OD_FLAGS_LENGTH_LONG:
sprintf(format, " %%%ulu", sizeof(long) * _INT_BYTE_LENGTH);
break;
#else /* !defined(__MACH__) */
#else /* !defined(__MACH__) */
case OD_FLAGS_BYTES_UINT | OD_FLAGS_LENGTH_SHORT:
sprintf(format, " %%%lu", sizeof(short) * _INT_BYTE_LENGTH);
break;
@ -177,7 +177,7 @@ static inline void _bytes_format(char *format, uint16_t flags)
case OD_FLAGS_BYTES_UINT | OD_FLAGS_LENGTH_LONG:
sprintf(format, " %%%lu", sizeof(long) * _INT_BYTE_LENGTH);
break;
#endif /* !defined(__MACH__) */
#endif /* !defined(__MACH__) */
case OD_FLAGS_BYTES_HEX | OD_FLAGS_LENGTH_1:
strncpy(format, " %02x", sizeof(" %02x"));
@ -203,7 +203,7 @@ static inline void _bytes_format(char *format, uint16_t flags)
case OD_FLAGS_BYTES_HEX | OD_FLAGS_LENGTH_LONG:
sprintf(format, " %%0%ulx", (unsigned)sizeof(long) * _HEX_BYTE_LENGTH);
break;
#else /* !defined(__MACH__) */
#else /* !defined(__MACH__) */
case OD_FLAGS_BYTES_HEX | OD_FLAGS_LENGTH_SHORT:
sprintf(format, " %%0%lx", sizeof(short) * _HEX_BYTE_LENGTH);
break;
@ -211,7 +211,7 @@ static inline void _bytes_format(char *format, uint16_t flags)
case OD_FLAGS_BYTES_HEX | OD_FLAGS_LENGTH_LONG:
sprintf(format, " %%0%lx", sizeof(long) * _HEX_BYTE_LENGTH);
break;
#endif /* !defined(__MACH__) */
#endif /* !defined(__MACH__) */
default:
break;