Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Make changes in the given C program. The given C program make a copy of any file using a system call in linux, edit the

Make changes in the given C program. The given C program make a copy of any file using a system call in linux, edit the so it will make a copy of bitmap file (image.bmp) and change the beige color to purple in a new file
image text in transcribed
FILE SYSTEMS 274 le copy program, Errr checking and reporting is minimal. / / include necessary header of include #include #include #include / ANSI prototype / use a bufer size of 4096 bytes /* protection bits for output file 1 th int main(int argc, char argv): #define BUF-SIZE 4096 #define OUTPUT-MODE 0700 int main(int argc, char argvl) int in_fd, out_fd, rd_count, wt_count; char buffer BUF_SIZE]: /* syntax error if argc is not 3 / if (argc !-3) exit(1); / Open the input file and create the output file/ in-fd = open(argv[1], O_RDONLY); /* open the source file */ if (in fd #include #include #include / ANSI prototype / use a bufer size of 4096 bytes /* protection bits for output file 1 th int main(int argc, char argv): #define BUF-SIZE 4096 #define OUTPUT-MODE 0700 int main(int argc, char argvl) int in_fd, out_fd, rd_count, wt_count; char buffer BUF_SIZE]: /* syntax error if argc is not 3 / if (argc !-3) exit(1); / Open the input file and create the output file/ in-fd = open(argv[1], O_RDONLY); /* open the source file */ if (in fd

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

The Structure Of The Relational Database Model

Authors: Jan Paredaens ,Paul De Bra ,Marc Gyssens ,Dirk Van Gucht

1st Edition

3642699588, 978-3642699580

More Books

Students also viewed these Databases questions