moved check for cmail.exe to beginning
This commit is contained in:
parent
499cd1487b
commit
15a4c8a8e1
@ -29,7 +29,7 @@ EnableGraphicalConsole(0)
|
||||
|
||||
Dim filelist$(0)
|
||||
|
||||
Global VERSION$="V1.06"
|
||||
Global VERSION$="V1.07"
|
||||
Global installme = 0
|
||||
Global updatesched = 0
|
||||
Global dryrun = 0
|
||||
@ -148,6 +148,14 @@ If ( FileSize ( SnapshotBin$ ) < 0 )
|
||||
End 1
|
||||
EndIf
|
||||
|
||||
Global MailCommand$ = BinPath$ + "\cmail.exe"
|
||||
|
||||
; CMail found ?
|
||||
If ( FileSize ( MailCommand$ ) < 0 And MailReport$ = "yes")
|
||||
PrintN("ERROR: [ " + MailCommand$ + " ] NOT found.")
|
||||
End 1
|
||||
EndIf
|
||||
|
||||
; Version check for Drive Snapshot ...
|
||||
DriveSnapshot = RunProgram(SnapshotBin$, "/?", "", #PB_Program_Open | #PB_Program_Read)
|
||||
If DriveSnapshot
|
||||
@ -206,14 +214,7 @@ Procedure IsAdmin()
|
||||
EndProcedure
|
||||
|
||||
Procedure LogSend(subject$)
|
||||
Protected MailCommand$ = BinPath$ + "\cmail.exe"
|
||||
|
||||
; CMail found ?
|
||||
If ( FileSize ( MailCommand$ ) < 0 )
|
||||
LogMe("ERROR: [ " + MailCommand$ + " ] NOT found.")
|
||||
ProcedureReturn false
|
||||
EndIf
|
||||
|
||||
; use debug mode ?
|
||||
If (MailDebug$ = "yes" )
|
||||
MailCommand$ + " -d"
|
||||
@ -231,7 +232,7 @@ Procedure LogSend(subject$)
|
||||
|
||||
; show full command in debug mode ...
|
||||
If (MailDebug$ = "yes" )
|
||||
Print(MailCommand$ + Chr($0d) + Chr($0a))
|
||||
PrintN(MailCommand$)
|
||||
EndIf
|
||||
|
||||
dummy=system(MailCommand$)
|
||||
@ -571,8 +572,8 @@ EndProg(e)
|
||||
|
||||
; IDE Options = PureBasic 5.73 LTS (Windows - x64)
|
||||
; ExecutableFormat = Console
|
||||
; CursorPosition = 236
|
||||
; FirstLine = 214
|
||||
; CursorPosition = 153
|
||||
; FirstLine = 141
|
||||
; Folding = --
|
||||
; EnableXP
|
||||
; Executable = snapcontrol.exe
|
||||
|
Loading…
Reference in New Issue
Block a user