Split the file into separate .c and .h files and added filter deletion