getMaxIndex hide unimportant errors
This commit is contained in:
parent
81cadece75
commit
5f1d2cc48a
@ -172,13 +172,18 @@ def getVersion(hkey,SOFTWARE):
|
|||||||
target["version"] = versionData
|
target["version"] = versionData
|
||||||
|
|
||||||
def getMaxIndex():
|
def getMaxIndex():
|
||||||
|
subprocess.run([
|
||||||
|
"wimlib-imagex","info",
|
||||||
|
target["path"],"1"
|
||||||
|
],check=True,stdout=subprocess.DEVNULL)
|
||||||
|
|
||||||
ind = 2
|
ind = 2
|
||||||
while True:
|
while True:
|
||||||
try:
|
try:
|
||||||
subprocess.run([
|
subprocess.run([
|
||||||
"wimlib-imagex","info",
|
"wimlib-imagex","info",
|
||||||
target["path"],str(ind)
|
target["path"],str(ind)
|
||||||
],check=True)
|
],check=True,stdout=subprocess.DEVNULL,stderr=subprocess.DEVNULL)
|
||||||
ind += 1
|
ind += 1
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
target["maxIndex"] = ind - 1
|
target["maxIndex"] = ind - 1
|
||||||
|
Loading…
Reference in New Issue
Block a user