98{
105 ULONG ulClusterSize = 0;
108
111
112
114 {
117 }
118
120 {
122 {
123
124 DPRINT(
"NoErr\n", pszSuffix);
126#if 0
128#endif
129 }
130 }
131
133 {
135 {
136
137 pszFileSystem = pszSuffix;
138 }
140 {
141
143 }
145 {
146
147 pszLabel = pszSuffix;
148 }
150 {
151
154 {
156 goto done;
157 }
158 }
160 {
161
162 ConPuts(
StdOut,
L"The RECOMMENDED option is not supported yet!\n");
163 }
165 {
166
168 }
170 {
171
173 }
175 {
176
178 }
180 {
181
183 }
185 {
186
188 }
190 {
191
192 }
193 else
194 {
197 }
198 }
199
203#if 0
205 {
208 break;
209
212 break;
213
216 break;
217
219 default:
221 break;
222 }
223#endif
224
225 DPRINT(
"FileSystem: %S\n", pszFileSystem);
226 DPRINT(
"Label: %S\n", pszLabel);
227 DPRINT(
"Quick: %d\n", bQuickFormat);
228 DPRINT(
"ClusterSize: %lu\n", ulClusterSize);
229
231
232
234 {
237 }
238
239 DPRINT(
"DriveRoot: %wZ\n", &usDriveRoot);
240
241
242 if (pszFileSystem ==
NULL)
243 pszFileSystem =
L"FAT";
244
246 if (
_wcsicmp(pszFileSystem,
L"FAT") == 0)
247 bBackwardCompatible =
TRUE;
248
249
250
251 if (pszLabel ==
NULL)
253
255
257 {
258 DPRINT1(
"GetFsModule() failed\n");
259 goto done;
260 }
261
263 if (pFormat)
264 {
265 Success = (pFormat)(&usDriveRoot,
267 bQuickFormat,
268 bBackwardCompatible,
271 ulClusterSize);
272 }
273
274done:
278 else
280
283
285
287}
#define IDS_SELECT_NO_VOLUME
#define IDS_ERROR_INVALID_ARGS
#define IDS_FORMAT_SUCCESS
void ConPuts(FILE *fp, LPCWSTR psz)
void ConResPrintf(FILE *fp, UINT nID,...)
void ConResPuts(FILE *fp, UINT nID)
BOOL HasPrefix(_In_ PWSTR pszString, _In_ PWSTR pszPrefix, _Out_opt_ PWSTR *pszSuffix)
#define GetProcAddress(x, y)
_ACRTIMP __msvcrt_ulong __cdecl wcstoul(const wchar_t *, wchar_t **, int)
_ACRTIMP int __cdecl _wcsicmp(const wchar_t *, const wchar_t *)
BOOLEAN(NTAPI * PULIB_FORMAT)(IN PUNICODE_STRING DriveRoot, IN PFMIFSCALLBACK Callback, IN BOOLEAN QuickFormat, IN BOOLEAN BackwardCompatible, IN MEDIA_TYPE MediaType, IN PUNICODE_STRING Label, IN ULONG ClusterSize)
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
NTSYSAPI BOOLEAN NTAPI RtlDosPathNameToNtPathName_U(_In_opt_z_ PCWSTR DosPathName, _Out_ PUNICODE_STRING NtPathName, _Out_opt_ PCWSTR *NtFileNamePart, _Out_opt_ PRTL_RELATIVE_NAME_U DirectoryInfo)
NTSYSAPI VOID NTAPI RtlInitUnicodeString(PUNICODE_STRING DestinationString, PCWSTR SourceString)
NTSYSAPI VOID NTAPI RtlFreeUnicodeString(PUNICODE_STRING UnicodeString)
WCHAR VolumeName[MAX_PATH]
WCHAR DeviceName[MAX_PATH]