modified version of capture.py to take in account the modification of snap.sh

Signed-off-by: Marc Oggier <marc.oggier@gmail.com>