Reactos
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

[REACTOS] Use standard conforming names

- Use _alloca instead of non-standard alloca
- Use _TCHAR instead of non-standard TCHAR
- Use _off_t instead of deprecated off_t
- Use _O_BINARY instead of O_BINARY

+41 -40
+1 -1
base/applications/cmdutils/attrib/attrib.c
··· 150 150 static BOOL 151 151 EnumFilesWorker( 152 152 _Inout_ PENUMFILES_CTX EnumCtx, 153 - _Inout_ off_t offFilePart) // Offset to the file name inside FullPathBuffer 153 + _Inout_ _off_t offFilePart) // Offset to the file name inside FullPathBuffer 154 154 { 155 155 BOOL bFound = FALSE; 156 156 HRESULT hRes;
+2 -2
base/shell/cmd/set.c
··· 278 278 #define PARSE_IDENT(ident, identlen, p) \ 279 279 do { \ 280 280 identlen = ident_len(p); \ 281 - ident = (LPTSTR)alloca((identlen + 1) * sizeof(TCHAR)); \ 281 + ident = (LPTSTR)_alloca((identlen + 1) * sizeof(TCHAR)); \ 282 282 memmove(ident, p, identlen * sizeof(TCHAR)); \ 283 283 ident[identlen] = 0; \ 284 284 p += identlen; \ ··· 681 681 return FALSE; 682 682 } 683 683 684 - buf = (LPTSTR)alloca(32 * sizeof(TCHAR)); 684 + buf = (LPTSTR)_alloca(32 * sizeof(TCHAR)); 685 685 _sntprintf(buf, 32, _T("%i"), identval); 686 686 SetEnvironmentVariable(ident, buf); // TODO FIXME - check return value 687 687 exprval = identval;
+1 -1
dll/win32/shell32/folders/CFSFolder.cpp
··· 872 872 else 873 873 { 874 874 INT cchElement = lstrlenW(lpszDisplayName) + 1; 875 - LPWSTR pszElement = (LPWSTR)alloca(cchElement * sizeof(WCHAR)); 875 + LPWSTR pszElement = (LPWSTR)_alloca(cchElement * sizeof(WCHAR)); 876 876 LPWSTR pchNext = lpszDisplayName; 877 877 hr = Shell_NextElement(&pchNext, pszElement, cchElement, TRUE); 878 878 if (FAILED(hr))
+3 -3
modules/rosapps/applications/cmdutils/cat/cat.c
··· 5 5 * PURPOSE: Concatenates STDIN or an arbitrary number of files to STDOUT 6 6 * PROGRAMMERS: David Welch 7 7 * Semyon Novikov (tappak) 8 - * Herm�s B�lusca - Ma�to 8 + * Hermès Bélusca - Maïto 9 9 */ 10 10 11 11 #include <stdio.h> ··· 54 54 } 55 55 56 56 /* Set STDOUT to binary */ 57 - _setmode(_fileno(stdout), O_BINARY); 57 + _setmode(_fileno(stdout), _O_BINARY); 58 58 59 59 /* Special case where we run 'cat' without any argument: we use STDIN */ 60 60 if (argc <= 1) ··· 62 62 unsigned int ch; 63 63 64 64 /* Set STDIN to binary */ 65 - _setmode(_fileno(stdin), O_BINARY); 65 + _setmode(_fileno(stdin), _O_BINARY); 66 66 67 67 #if 0 // Version using feof() 68 68 ch = fgetc(stdin);
+2 -2
sdk/include/crt/unistd.h
··· 26 26 #define FTRUNCATE_DEFINED 27 27 /* This is defined as a real library function to allow autoconf 28 28 to verify its existence. */ 29 - int ftruncate(int, off_t); 30 - __CRT_INLINE int ftruncate(int __fd, off_t __length) 29 + int ftruncate(int, _off_t); 30 + __CRT_INLINE int ftruncate(int __fd, _off_t __length) 31 31 { 32 32 return _chsize (__fd, __length); 33 33 }
+1
sdk/include/reactos/wine/port.h
··· 91 91 # endif /* defined(__BEOS__) */ 92 92 #endif /* !defined(HAVE_STATFS) */ 93 93 94 + struct stat; 94 95 95 96 /**************************************************************** 96 97 * Macro definitions
+6 -6
sdk/lib/crt/printf/_sxprintf.c
··· 22 22 23 23 #define min(a,b) (((a) < (b)) ? (a) : (b)) 24 24 25 - int __cdecl _tstreamout(FILE *stream, const TCHAR *format, va_list argptr); 25 + int __cdecl _tstreamout(FILE *stream, const _TCHAR *format, va_list argptr); 26 26 27 27 int 28 28 #if defined(USER32_WSPRINTF) && defined(_M_IX86) ··· 31 31 __cdecl 32 32 #endif 33 33 _sxprintf( 34 - TCHAR *buffer, 34 + _TCHAR *buffer, 35 35 #if IS_SECAPI 36 36 size_t sizeOfBuffer, 37 37 #endif 38 38 #if USE_COUNT 39 39 size_t count, 40 40 #endif 41 - const TCHAR *format, 41 + const _TCHAR *format, 42 42 #if USE_VARARGS 43 43 va_list argptr) 44 44 #else ··· 74 74 stream._base = (char*)buffer; 75 75 stream._ptr = stream._base; 76 76 stream._charbuf = 0; 77 - stream._cnt = (int)(sizeOfBuffer * sizeof(TCHAR)); 77 + stream._cnt = (int)(sizeOfBuffer * sizeof(_TCHAR)); 78 78 stream._bufsiz = 0; 79 79 stream._flag = _IOSTRG | _IOWRT; 80 80 stream._tmpfname = 0; ··· 112 112 buffer[result] = _T('\0'); 113 113 #else 114 114 /* Only zero terminate if there is enough space left */ 115 - if ((stream._cnt >= sizeof(TCHAR)) && (stream._ptr)) 116 - *(TCHAR*)stream._ptr = _T('\0'); 115 + if ((stream._cnt >= sizeof(_TCHAR)) && (stream._ptr)) 116 + *(_TCHAR*)stream._ptr = _T('\0'); 117 117 #endif 118 118 119 119 return result;
+23 -23
sdk/lib/crt/printf/streamout.c
··· 80 80 __declspec(noinline) 81 81 #endif 82 82 format_float( 83 - TCHAR chr, 83 + _TCHAR chr, 84 84 unsigned int flags, 85 85 int precision, 86 - TCHAR **string, 87 - const TCHAR **prefix, 86 + _TCHAR **string, 87 + const _TCHAR **prefix, 88 88 va_list *argptr) 89 89 { 90 - static const TCHAR digits_l[] = _T("0123456789abcdef0x"); 91 - static const TCHAR digits_u[] = _T("0123456789ABCDEF0X"); 92 - static const TCHAR _nan[] = _T("#QNAN"); 93 - static const TCHAR _infinity[] = _T("#INF"); 94 - const TCHAR *digits = digits_l; 90 + static const _TCHAR digits_l[] = _T("0123456789abcdef0x"); 91 + static const _TCHAR digits_u[] = _T("0123456789ABCDEF0X"); 92 + static const _TCHAR _nan[] = _T("#QNAN"); 93 + static const _TCHAR _infinity[] = _T("#INF"); 94 + const _TCHAR *digits = digits_l; 95 95 int exponent = 0, sign; 96 96 long double fpval, fpval2; 97 97 int padding = 0, num_digits, val32, base = 10; ··· 186 186 /* Handle special cases first */ 187 187 if (_isnan(fpval)) 188 188 { 189 - (*string) -= sizeof(_nan) / sizeof(TCHAR) - 1; 189 + (*string) -= sizeof(_nan) / sizeof(_TCHAR) - 1; 190 190 _tcscpy((*string), _nan); 191 191 fpval2 = 1; 192 192 } 193 193 else if (!_finite(fpval)) 194 194 { 195 - (*string) -= sizeof(_infinity) / sizeof(TCHAR) - 1; 195 + (*string) -= sizeof(_infinity) / sizeof(_TCHAR) - 1; 196 196 _tcscpy((*string), _infinity); 197 197 fpval2 = 1; 198 198 } ··· 234 234 #endif 235 235 #if defined(_USER32_WSPRINTF) || defined(_LIBCNT_) 236 236 /* Check if the buffer is full */ 237 - if (stream->_cnt < sizeof(TCHAR)) 237 + if (stream->_cnt < sizeof(_TCHAR)) 238 238 return 0; 239 239 240 - *(TCHAR*)stream->_ptr = chr; 241 - stream->_ptr += sizeof(TCHAR); 242 - stream->_cnt -= sizeof(TCHAR); 240 + *(_TCHAR*)stream->_ptr = chr; 241 + stream->_ptr += sizeof(_TCHAR); 242 + stream->_cnt -= sizeof(_TCHAR); 243 243 244 244 return 1; 245 245 #else 246 - return _fputtc((TCHAR)chr, stream) != _TEOF; 246 + return _fputtc((_TCHAR)chr, stream) != _TEOF; 247 247 #endif 248 248 } 249 249 ··· 251 251 int 252 252 streamout_astring(FILE *stream, const char *string, size_t count) 253 253 { 254 - TCHAR chr; 254 + _TCHAR chr; 255 255 int written = 0; 256 256 257 257 #if !defined(_USER32_WSPRINTF) ··· 323 323 324 324 int 325 325 __cdecl 326 - streamout(FILE *stream, const TCHAR *format, va_list argptr) 326 + streamout(FILE *stream, const _TCHAR *format, va_list argptr) 327 327 { 328 - static const TCHAR digits_l[] = _T("0123456789abcdef0x"); 329 - static const TCHAR digits_u[] = _T("0123456789ABCDEF0X"); 328 + static const _TCHAR digits_l[] = _T("0123456789abcdef0x"); 329 + static const _TCHAR digits_u[] = _T("0123456789ABCDEF0X"); 330 330 static const char *_nullstring = "(null)"; 331 - TCHAR buffer[BUFFER_SIZE + 1]; 332 - TCHAR chr, *string; 331 + _TCHAR buffer[BUFFER_SIZE + 1]; 332 + _TCHAR chr, *string; 333 333 STRING *nt_string; 334 - const TCHAR *digits, *prefix; 334 + const _TCHAR *digits, *prefix; 335 335 int base, fieldwidth, precision, padding; 336 336 size_t prefixlen, len; 337 337 int written = 1, written_all = 0; ··· 534 534 case_string: 535 535 if (!string) 536 536 { 537 - string = (TCHAR*)_nullstring; 537 + string = (_TCHAR*)_nullstring; 538 538 flags &= ~FLAG_WIDECHAR; 539 539 } 540 540
+1 -1
sdk/lib/crt/startup/crtexe.c
··· 211 211 /* We need to make sure that this function is build with frame-pointer 212 212 and that we align the stack to 16 bytes for the sake of SSE ops in main 213 213 or in functions inlined into main. */ 214 - lpszCommandLine = (_TCHAR *) alloca (32); 214 + lpszCommandLine = (_TCHAR *) _alloca (32); 215 215 memset (lpszCommandLine, 0xcc, 32); 216 216 #ifdef __GNUC__ 217 217 asm __volatile__ ("andl $-16, %%esp" : : : "%esp");
+1 -1
sdk/lib/crt/startup/pseudo-reloc.c
··· 464 464 ++was_init; 465 465 #ifdef __MINGW64_VERSION_MAJOR 466 466 mSecs = __mingw_GetSectionCount (); 467 - the_secs = (sSecInfo *) alloca (sizeof (sSecInfo) * (size_t) mSecs); 467 + the_secs = (sSecInfo *) _alloca (sizeof (sSecInfo) * (size_t) mSecs); 468 468 maxSections = 0; 469 469 #endif /* __MINGW64_VERSION_MAJOR */ 470 470