(svn r7200) -Codechange: remove unneeded redraw (console.c), coding style, use FindWindowById

instead of _windows loop (viewport.c), remove dump-code (mixer.c), MSVC6 borkdness
 in stdafx.h, constness (viewport.c), variable localization (win32.c), comments (window.c)
This commit is contained in:
Darkvater
2006-11-18 00:14:43 +00:00
parent 2754eeb989
commit c4d841dcdb
8 changed files with 43 additions and 51 deletions

View File

@@ -637,7 +637,6 @@ static inline void dir_free(DIR *d)
DIR *opendir(const char *path)
{
char search_path[MAX_PATH];
DIR *d;
UINT sem = SetErrorMode(SEM_FAILCRITICALERRORS); // disable 'no-disk' message box
DWORD fa = GetFileAttributes(path);
@@ -645,6 +644,7 @@ DIR *opendir(const char *path)
if ((fa != INVALID_FILE_ATTRIBUTES) && (fa & FILE_ATTRIBUTE_DIRECTORY)) {
d = dir_calloc();
if (d != NULL) {
char search_path[MAX_PATH];
/* build search path for FindFirstFile */
snprintf(search_path, lengthof(search_path), "%s" PATHSEP "*", path);
d->hFind = FindFirstFile(search_path, &d->fd);
@@ -893,7 +893,7 @@ void DeterminePaths(void)
GetCurrentDirectory(MAX_PATH - 1, cfg);
cfg[0] = toupper(cfg[0]);
s = strchr(cfg, 0);
s = strchr(cfg, '\0');
if (s[-1] != '\\') strcpy(s, "\\");
_path.save_dir = str_fmt("%ssave", cfg);