This commit is contained in:
Mario Stöckl 2025-07-03 23:45:32 +02:00
parent 48dcb7155e
commit fff2f54164
2 changed files with 6 additions and 6 deletions

BIN
bin/main

Binary file not shown.

View File

@ -68,14 +68,14 @@ int checkparams(int *argc, char *argv[]) {
struct access_log_entry_t parseLogline(char *accessLogLine) { struct access_log_entry_t parseLogline(char *accessLogLine) {
struct access_log_entry_t logEntry; struct access_log_entry_t logEntry;
logEntry.remote_addr = parse_remote_address(accessLogLine); // logEntry.remote_addr = parse_remote_address(accessLogLine);
return logEntry; return logEntry;
}; };
char parse_remote_address(char *accessLogLine) { //char* parse_remote_address(char *accessLogLine) {
char *remote_adress[18]; // char *remote_adress[18];
regcomp // regcomp
} //}
uint32_t my_strlen(char *s) { uint32_t my_strlen(char *s) {
uint32_t counter = 0; uint32_t counter = 0;
@ -120,7 +120,7 @@ int main(int argc, char *argv[]) {
// fputs(outputline, stdout); // fputs(outputline, stdout);
// debugmsg("endloop"); // debugmsg("endloop");
//} //}
for (int counter = 0; counter < 10 && fgets(access_log_buffer, filesize, fp); counter++) { for (int counter = 0; counter < 10 && fgets(access_log_buffer, BUF, fp); counter++) {
//debugmsg("entered loop"); //debugmsg("entered loop");
char outputline[BUF]; char outputline[BUF];
sprintf(outputline, "LINE %d: %s", counter+1, access_log_buffer); sprintf(outputline, "LINE %d: %s", counter+1, access_log_buffer);