Sync with Enterprise version
- Sync to commit fcebdc17f3b7f9ea99e9430c951ac74044910114 "Fix broken use
with --oneshot"
Change-Id: I65450ecfc40d11fc3117303e66938751208a6b8d
diff --git a/snapshot b/snapshot
index 0aac41d..551d687 100755
--- a/snapshot
+++ b/snapshot
@@ -32,7 +32,7 @@
SRC_WIDTH = 2592
SRC_HEIGHT = 1944
SRC_RATE = '15/1'
-SRC_ELEMENT = 'v4l2src device=/dev/video0'
+SRC_ELEMENT = 'v4l2src'
SINK_WIDTH = 2592
SINK_HEIGHT = 1944
@@ -165,6 +165,7 @@
self.scrapframes = SCRAP_FRAMES
self.sysfs = sysfs
self.loop = None
+ self.thread = None
if not oneshot:
self.pipe_r, self.pipe_w = os.pipe()
@@ -244,7 +245,8 @@
def connect_loop(self, loop):
self.loop = loop
- self.thread.start()
+ if self.thread:
+ self.thread.start()
def main(arguments):