Corewar documentation 1.0.0
Loading...
Searching...
No Matches
header.c File Reference

The file containing the header functions. More...

Functions

int is_valid_magic (char *header)
 Check if the magic number is valid.
 
int get_prog_size (char *header)
 Get the program size.
 

Detailed Description

The file containing the header functions.

Function Documentation

◆ get_prog_size()

int get_prog_size ( char * header)

Get the program size.

Parameters
headerThe header of the program
Returns
int The program size

◆ is_valid_magic()

int is_valid_magic ( char * header)

Check if the magic number is valid.

Parameters
headerThe header of the program
Returns
int 1 if the magic number is valid, 0 otherwise