Skip to content

Commit

Permalink
Merge pull request #69 from calebccff/ppps-segfault
Browse files Browse the repository at this point in the history
ppps: check if ppps3_path is valid
  • Loading branch information
lumag authored Mar 12, 2024
2 parents d678216 + 98b4aa8 commit baa48a8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ppps.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ void ppps_power(struct device *dev, bool on)
dev->ppps_path = temp;
}

if (dev->ppps3_path[0] != '/') {
if (dev->ppps3_path && dev->ppps3_path[0] != '/') {
char *temp;

asprintf(&temp, PPPS_BASE_PATH, dev->ppps3_path);
Expand Down

0 comments on commit baa48a8

Please sign in to comment.