From daefc1d442fb421606680feb9aeb59c133f4c427 Mon Sep 17 00:00:00 2001 From: Doug Zongker Date: Mon, 31 Oct 2011 09:34:15 -0700 Subject: C++ class for device-specific code Replace the device-specific functions with a class. Move some of the key handling (for log visibility toggling and rebooting) into the UI class. Fix up the key handling so there is less crosstalk between the immediate keys and the queued keys (an increasing annoyance on button-limited devices). Change-Id: I698f6fd21c67a1e55429312a0484b6c393cad46f --- updater/install.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'updater/install.c') diff --git a/updater/install.c b/updater/install.c index 7b4b99b01..f68bd03c8 100644 --- a/updater/install.c +++ b/updater/install.c @@ -792,11 +792,12 @@ Value* WriteRawImageFn(const char* name, State* state, int argc, Expr* argv[]) { return NULL; } + char* partition = NULL; if (partition_value->type != VAL_STRING) { ErrorAbort(state, "partition argument to %s must be string", name); goto done; } - char* partition = partition_value->data; + partition = partition_value->data; if (strlen(partition) == 0) { ErrorAbort(state, "partition argument to %s can't be empty", name); goto done; -- cgit v1.2.3