kif.py [293:319]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                    if not ('ignore' in rule):
                        addit = True
                    elif isinstance(rule['ignore'], str) and cmdstring != rule['ignore']:
                        addit = True
                    elif isinstance(rule['ignore'], list) and cmdline != rule['ignore']:
                        addit = True
                    if 'ignorepidfile' in rule:
                        try:
                            ppid = int(open(rule['ignorepidfile']).read())
                            if ppid == xpid:
                                # print(f"Ignoring {ppid}, matches pid file {rule['ignorepidfile']}!")
                                addit = False
                        except Exception as err:
                            print(err)
                    if 'ignorematch' in rule:
                        ignm = rule['ignorematch']
                        if isinstance(ignm, str) and ignm in cmdstring:
                            # print(f"Ignoring {xpid}, matches ignorematch directive {rule['ignorematch']}!")
                            addit = False
                        elif isinstance(ignm, list):
                            for line in ignm:
                                if line in cmdstring:
                                    # print(f"Ignoring {xpid}, matches ignorematch directive {line}!")
                                    addit = False
                                    break
                    if addit:
                        pids.append(xpid)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



kif.py [326:352]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                    if not ('ignore' in rule):
                        addit = True
                    elif isinstance(rule['ignore'], str) and cmdstring != rule['ignore']:
                        addit = True
                    elif isinstance(rule['ignore'], list) and cmdline != rule['ignore']:
                        addit = True
                    if 'ignorepidfile' in rule:
                        try:
                            ppid = int(open(rule['ignorepidfile']).read())
                            if ppid == xpid:
                                # print(f"Ignoring {ppid}, matches pid file {rule['ignorepidfile']}!")
                                addit = False
                        except Exception as err:
                            print(err)
                    if 'ignorematch' in rule:
                        ignm = rule['ignorematch']
                        if isinstance(ignm, str) and ignm in cmdstring:
                            # print(f"Ignoring {xpid}, matches ignorematch directive {rule['ignorematch']}!")
                            addit = False
                        elif isinstance(ignm, list):
                            for line in ignm:
                                if line in cmdstring:
                                    # print(f"Ignoring {xpid}, matches ignorematch directive {line}!")
                                    addit = False
                                    break
                    if addit:
                        pids.append(xpid)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



