FOSSology  4.4.0
Open Source License Compliance by Open Source Software
match.c
Go to the documentation of this file.
1 /*
2  SPDX-FileCopyrightText: © 2010 Hewlett-Packard Development Company, L.P.
3 
4  SPDX-License-Identifier: GPL-2.0-only
5 */
6 
12 #include "buckets.h"
13 
14 
24 FUNCTION int matchAnyLic(PGresult *result, int numLics, regex_t *compRegex)
25 {
26  int licNumb;
27  char *licName;
28 
29  for (licNumb=0; licNumb < numLics; licNumb++)
30  {
31  licName = PQgetvalue(result, licNumb, 0);
32  if (0 == regexec(compRegex, licName, 0, 0, 0)) return 1;
33  }
34  return 0;
35 }
FUNCTION int matchAnyLic(PGresult *result, int numLics, regex_t *compRegex)
Does this regex match any license name for this pfile?
Definition: match.c:24