MCPcopy Create free account
hub / github.com/abbeycode/UnrarKit / SetStoreTimeMode

Method SetStoreTimeMode

Libraries/unrar/cmdfilter.cpp:312–351  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

310
311#if !defined(SFX_MODULE)
312void CommandData::SetStoreTimeMode(const wchar *S)
313{
314 if (*S==0 || IsDigit(*S) || *S=='-' || *S=='+')
315 {
316 // Apply -ts, -ts1, -ts-, -ts+ to all 3 times.
317 // Handle obsolete -ts[2,3,4] as ts+.
318 EXTTIME_MODE Mode=EXTTIME_MAX;
319 if (*S=='-')
320 Mode=EXTTIME_NONE;
321 if (*S=='1')
322 Mode=EXTTIME_1S;
323 xmtime=xctime=xatime=Mode;
324 S++;
325 }
326
327 while (*S!=0)
328 {
329 EXTTIME_MODE Mode=EXTTIME_MAX;
330 if (S[1]=='-')
331 Mode=EXTTIME_NONE;
332 if (S[1]=='1')
333 Mode=EXTTIME_1S;
334 switch(toupperw(*S))
335 {
336 case 'M':
337 xmtime=Mode;
338 break;
339 case 'C':
340 xctime=Mode;
341 break;
342 case 'A':
343 xatime=Mode;
344 break;
345 case 'P':
346 PreserveAtime=true;
347 break;
348 }
349 S++;
350 }
351}
352#endif

Callers

nothing calls this directly

Calls 2

IsDigitFunction · 0.85
toupperwFunction · 0.85

Tested by

no test coverage detected