From 758af77e9d1c3c6e5aea365bc0d35c385278ad5a Mon Sep 17 00:00:00 2001 From: Anatol Belski Date: Thu, 22 Dec 2016 14:56:47 +0100 Subject: Path handling related refactorings Primarily related to the path handling datatypes, to avoid unnecessary casts, where possible. Also some rework to avoid code dup. Probably more places are to go, even not path related, primarily to have less casts and unsigned integers where possible. That way, we've not only less warnings and casts, but are also safer with regard to the integer overflows. OFC it's not a panacea, but still significantly reduces the vulnerability potential. --- win32/readdir.c | 10 ---------- 1 file changed, 10 deletions(-) (limited to 'win32/readdir.c') diff --git a/win32/readdir.c b/win32/readdir.c index 4a6d65932f..43d5deecfd 100644 --- a/win32/readdir.c +++ b/win32/readdir.c @@ -24,16 +24,6 @@ extern "C" { #endif -/* typedef DIR - not the same as Unix */ -struct DIR_W32 { - HANDLE handle; /* _findfirst/_findnext handle */ - int offset; /* offset into directory */ - short finished; /* 1 if there are not more files */ - WIN32_FIND_DATAW fileinfo; /* from _findfirst/_findnext */ - wchar_t *dirw; /* the dir we are reading */ - struct dirent dent; /* the dirent to return */ -}; - DIR *opendir(const char *dir) { DIR *dp; -- cgit v1.2.1