Simple way to check if a string contains another string in C? [duplicate]

Solution 1:

if (strstr(request, "favicon") != NULL) {
    // contains
}

Solution 2:

strstr(request, "favicon") != NULL