Question
in the linux system modify the given .c file that can run the contents by mmap'ing it into an array. The purpose is change the
in the linux system
modify the given .c file that can run the contents by mmap'ing it into an array. The purpose is change the array pointer into a function pointer. The called function should have the same declaration as write(), call it with (1, "Hello there! ", 13).When your program is given the file .bin as a command-line argument, it should print out "Hello there!"
the original .c is: https://homeostasis.scs.carleton.ca/~soma/os-2017f/code/tut3/3000test.c
the binary file is here:https://homeostasis.scs.carleton.ca/~soma/os-2019w/code/write.bin
you can use "diff -c" to shows the changed part.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started