summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian Ashworth <bosrsf04@gmail.com>2019-03-11 00:10:18 -0400
committerDrew DeVault <sir@cmpwn.com>2019-03-11 10:57:16 -0400
commitc01a3ca538ae53e9981e99b3aecadca23b1737ba (patch)
treec099cda9ea92577ff841f8d1ef508bd6e71a6371
parent80343587cc605eefc62a9f132e0528cfd47caabf (diff)
detect_proprietary: use strncmp
Only the main nvidia module needs to be blocked. Others such as nvidiafb are benign and do not need to be blocked
-rw-r--r--sway/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sway/main.c b/sway/main.c
index 22b728131..f3cc1bc8b 100644
--- a/sway/main.c
+++ b/sway/main.c
@@ -91,7 +91,7 @@ void detect_proprietary(int allow_unsupported_gpu) {
char *line = NULL;
size_t line_size = 0;
while (getline(&line, &line_size, f) != -1) {
- if (strstr(line, "nvidia")) {
+ if (strncmp(line, "nvidia ", 7) == 0) {
if (allow_unsupported_gpu) {
sway_log(SWAY_ERROR,
"!!! Proprietary Nvidia drivers are in use !!!");