Skip to content

Commit

Permalink
still fixing bug from last commit
Browse files Browse the repository at this point in the history
  • Loading branch information
tihmstar committed Jan 3, 2017
1 parent 49ed265 commit daadf3e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tsschecker/tsschecker.c
Original file line number Diff line number Diff line change
Expand Up @@ -223,8 +223,12 @@ plist_t getBuildidentityWithBoardconfig(plist_t buildManifest, const char *board
plist_get_string_val(RestoreBehavior, &string);
//assuming there are only Erase and Update. If it's not Erase it must be Update
//also converting isUpdateInstall to bool (1 or 0)
if (strncmp(string, "Erase", strlen(string)) != (isUpdateInstall != 0))
if ((strncmp(string, "Erase", strlen(string)) != 0) == !isUpdateInstall){
//continue when Erase found but isUpdateInstall is true
//or Update found and isUpdateInstall is false
rt = NULL;
continue;
}

plist_t DeviceClass = plist_dict_get_item(infodict, "DeviceClass");
if (!DeviceClass || plist_get_node_type(DeviceClass) != PLIST_STRING){
Expand Down

0 comments on commit daadf3e

Please sign in to comment.