read the -r param, it is needed here when only one thread is used...
explicitly state that bin/bash is needed, not 100% sure if it is supposed to work if a plain sh is used...
This commit is contained in:
parent
d3c74f041e
commit
f54d9ff134
1 changed files with 2 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
|||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
#
|
||||
# Script to strip ICC profiles from all png images and to recompress them
|
||||
# afterwards via optipng and advdef
|
||||
|
@ -191,7 +191,7 @@ echo "* compressing the files *"
|
|||
echo "*************************"
|
||||
for f in $filelist
|
||||
do
|
||||
while [ $(jobs -p | wc -l) -ge $max_number_threads ]
|
||||
while [ $(jobs -pr | wc -l) -ge $max_number_threads ]
|
||||
do
|
||||
# max number of threads reached, wait for a quarter second...
|
||||
sleep 0.25
|
||||
|
|
Loading…
Add table
Reference in a new issue