RCS file: declerations.h,v
Working file: declerations.h
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
Thius file would contain for all declerations in the Project.
declared mainMenu(), exitFunc(), compression(), deCompression()
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 09:59:30; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This file contains all included headers and Macros
included stdio.h and stdlib.h.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:00:05; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function would initiate the compression operation. Just checking mapping for now.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:01:36; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: deCompression.c,v
Working file: deCompression.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This funcion would initiate deCompression() operation. Just checking for mapping for now.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:02:28; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: exitFunc.c,v
Working file: exitFunc.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function will be used for exiting the project.
exiting for success using exit()
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:03:09; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This is the Main Project Source File
Project: Multiple Data Compression and Encryption using Iterative Technique.
In an infinite loop, calling mainMenu() and getting the choice.
Depending on the choice, calling the appropriate function using switch.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:03:45; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: mainMenu.c,v
Working file: mainMenu.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function would...
display main menu, get choice from user and return choice to main().
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:05:20; author: root; state: Exp;
Initial revision
=============================================================================
@page { margin: 0.79in }
pre.cjk { font-family: "DejaVu Sans Mono", monospace }
p { margin-bottom: 0.1in; line-height: 120% }
RCS file: declerations.h,v
Working file: declerations.h
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
Thius file would contain for all declerations in the Project.
declared mainMenu(), exitFunc(), compression(), deCompression()
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 09:59:30; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This file contains all included headers and Macros
included stdio.h and stdlib.h.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:00:05; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function would initiate the compression operation. Just checking mapping for now.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:01:36; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: exitFunc.c,v
Working file: exitFunc.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function will be used for exiting the project.
exiting for success using exit()
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:03:09; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This is the Main Project Source File
Project: Multiple Data Compression and Encryption using Iterative Technique.
In an infinite loop, calling mainMenu() and getting the choice.
Depending on the choice, calling the appropriate function using switch.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:03:45; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: declerations.h,v
Working file: declerations.h
head: 1.2
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
Thius file would contain for all declerations in the Project.
declared mainMenu(), exitFunc(), compression(), deCompression()
----------------------------
revision 1.2
date: 2018/12/10 10:27:09; author: root; state: Exp; lines: +2 -1
declared openFile()
updates exitFunc()... passing the exit status as argument.
----------------------------
revision 1.1
date: 2018/12/10 09:59:30; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.2
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This file contains all included headers and Macros
included stdio.h and stdlib.h.
----------------------------
revision 1.2
date: 2018/12/10 10:31:49; author: root; state: Exp; lines: +3 -0
included string.h, usistd.h and fcntl.h
----------------------------
revision 1.1
date: 2018/12/10 10:00:05; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.2
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This function would initiate the compression operation. Just checking mapping for now.
----------------------------
revision 1.2
date: 2018/12/10 10:28:07; author: root; state: Exp; lines: +4 -0
calling openFile() to open the file.
getting fd from this func and printing.
----------------------------
revision 1.1
date: 2018/12/10 10:01:36; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: exitFunc.c,v
Working file: exitFunc.c
head: 1.2
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This function will be used for exiting the project.
exiting for success using exit()
----------------------------
revision 1.2
date: 2018/12/10 10:28:40; author: root; state: Exp; lines: +5 -2
Now accepting exit ststus as argument.
checking argument using strncmp() and xiting accordingly.
----------------------------
revision 1.1
date: 2018/12/10 10:03:09; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.2
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This is the Main Project Source File
Project: Multiple Data Compression and Encryption using Iterative Technique.
In an infinite loop, calling mainMenu() and getting the choice.
Depending on the choice, calling the appropriate function using switch.
----------------------------
revision 1.2
date: 2018/12/10 10:29:16; author: root; state: Exp; lines: +1 -1
undated the exit() call, giving the exit status as argument
----------------------------
revision 1.1
date: 2018/12/10 10:03:45; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: openFile.c,v
Working file: openFile.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
allocated space for filename.
Got the filename from user.
The function gets open mode as argument. check open mode using strncmp() and open the file in appropriate mde.
check for error
return the file descriptor
----------------------------
revision 1.1
date: 2018/12/10 10:29:42; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: declerations.h,v
Working file: declerations.h
head: 1.3
branch:
locks: strict
root: 1.3
access list:
symbolic names:
keyword substitution: kv
total revisions: 3; selected revisions: 3
description:
Thius file would contain for all declerations in the Project.
declared mainMenu(), exitFunc(), compression(), deCompression()
----------------------------
revision 1.3 locked by: root;
date: 2018/12/13 08:57:54; author: root; state: Exp; lines: +1 -0
declared createMasterArray()
----------------------------
revision 1.2
date: 2018/12/10 10:27:09; author: root; state: Exp; lines: +2 -1
declared openFile()
updates exitFunc()... passing the exit status as argument.
----------------------------
revision 1.1
date: 2018/12/10 09:59:30; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.2
branch:
locks: strict
root: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This file contains all included headers and Macros
included stdio.h and stdlib.h.
----------------------------
revision 1.2 locked by: root;
date: 2018/12/10 10:31:49; author: root; state: Exp; lines: +3 -0
included string.h, usistd.h and fcntl.h
----------------------------
revision 1.1
date: 2018/12/10 10:00:05; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.3
branch:
locks: strict
root: 1.3
access list:
symbolic names:
keyword substitution: kv
total revisions: 3; selected revisions: 3
description:
This function would initiate the compression operation. Just checking mapping for now.
----------------------------
revision 1.3 locked by: root;
date: 2018/12/13 09:01:09; author: root; state: Exp; lines: +1 -0
Calling createMasterArray() and gived the opened file descriptor as arument.
This function should return the masterArray(). i.e. array of unique characters.
----------------------------
revision 1.2
date: 2018/12/10 10:28:07; author: root; state: Exp; lines: +4 -0
calling openFile() to open the file.
getting fd from this func and printing.
----------------------------
revision 1.1
date: 2018/12/10 10:01:36; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: createMasterArray.c,v
Working file: createMasterArray.c
head: 1.4
branch:
locks: strict
root: 1.4
access list:
symbolic names:
keyword substitution: kv
total revisions: 4; selected revisions: 4
description:
This function would create an array of unique characters from opened file and return it to the compresion()
----------------------------
revision 1.4 locked by: root;
date: 2018/12/13 09:10:01; author: root; state: Exp; lines: +1 -1
Storingend-of-file char one position bofore the end of file.
----------------------------
revision 1.3
date: 2018/12/13 09:08:55; author: root; state: Exp; lines: +1 -0
Appending the end-of-string to the masterarray.
----------------------------
revision 1.2
date: 2018/12/13 09:06:46; author: root; state: Exp; lines: +11 -2
Earlier we were printingthe chars read from file. Now, we would store the chars read from file into an array.
then after reading from file is over, we print the array.
----------------------------
revision 1.1
date: 2018/12/13 09:02:21; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: declerations.h,v
Working file: declerations.h
head: 1.5
branch:
locks: strict
root: 1.5
access list:
symbolic names:
keyword substitution: kv
total revisions: 5; selected revisions: 5
description:
Thius file would contain for all declerations in the Project.
declared mainMenu(), exitFunc(), compression(), deCompression()
----------------------------
revision 1.5 locked by: root;
date: 2018/12/14 11:44:38; author: root; state: Exp; lines: +1 -0
declared unique()
----------------------------
revision 1.4
date: 2018/12/14 11:34:38; author: root; state: Exp; lines: +1 -1
Updated decleration for creatMasterArray()
It now returns char*
----------------------------
revision 1.3
date: 2018/12/13 08:57:54; author: root; state: Exp; lines: +1 -0
declared createMasterArray()
----------------------------
revision 1.2
date: 2018/12/10 10:27:09; author: root; state: Exp; lines: +2 -1
declared openFile()
updates exitFunc()... passing the exit status as argument.
----------------------------
revision 1.1
date: 2018/12/10 09:59:30; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.2
branch:
locks: strict
root: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This file contains all included headers and Macros
included stdio.h and stdlib.h.
----------------------------
revision 1.2 locked by: root;
date: 2018/12/10 10:31:49; author: root; state: Exp; lines: +3 -0
included string.h, usistd.h and fcntl.h
----------------------------
revision 1.1
date: 2018/12/10 10:00:05; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.4
branch:
locks: strict
root: 1.4
access list:
symbolic names:
keyword substitution: kv
total revisions: 4; selected revisions: 4
description:
This function would initiate the compression operation. Just checking mapping for now.
----------------------------
revision 1.4 locked by: root;
date: 2018/12/14 11:35:03; author: root; state: Exp; lines: +3 -1
Captured thwe return value from creatMasterArray() and printed it.
----------------------------
revision 1.3
date: 2018/12/13 09:01:09; author: root; state: Exp; lines: +1 -0
Calling createMasterArray() and gived the opened file descriptor as arument.
This function should return the masterArray(). i.e. array of unique characters.
----------------------------
revision 1.2
date: 2018/12/10 10:28:07; author: root; state: Exp; lines: +4 -0
calling openFile() to open the file.
getting fd from this func and printing.
----------------------------
revision 1.1
date: 2018/12/10 10:01:36; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: createMasterArray.c,v
Working file: createMasterArray.c
head: 1.6
branch:
locks: strict
root: 1.6
access list:
symbolic names:
keyword substitution: kv
total revisions: 6; selected revisions: 6
description:
This function would create an array of unique characters from opened file and return it to the compresion()
----------------------------
revision 1.6 locked by: root;
date: 2018/12/14 11:44:49; author: root; state: Exp; lines: +2 -1
After reading the char from file, we call unique() to check if the char is unique/not found in masterarray.
Then only we store it in the masterarray.
This is done by calling unique() in the if()
unique() return 1 if char is unique else if the char is found in ther array it treturn 0
----------------------------
revision 1.5
date: 2018/12/14 11:35:34; author: root; state: Exp; lines: +2 -2
The created Master Array is returned.
The return type of function is updated acccordingly.
----------------------------
revision 1.4
date: 2018/12/13 09:10:01; author: root; state: Exp; lines: +1 -1
Storingend-of-file char one position bofore the end of file.
----------------------------
revision 1.3
date: 2018/12/13 09:08:55; author: root; state: Exp; lines: +1 -0
Appending the end-of-string to the masterarray.
----------------------------
revision 1.2
date: 2018/12/13 09:06:46; author: root; state: Exp; lines: +11 -2
Earlier we were printingthe chars read from file. Now, we would store the chars read from file into an array.
then after reading from file is over, we print the array.
----------------------------
revision 1.1
date: 2018/12/13 09:02:21; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: unique.c,v
Working file: unique.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
Thius functio would check the character in question into the masterarray.for uniqueness.
It takes masterarray, char and size of array as argument.
if the size is zero. t return true(first char)\
else
it scans using th for loop the who array, if the char is found it return 0.
if the for loop is over but the char was never found, that means that the char is unique, it returns 1
----------------------------
revision 1.1 locked by: root;
date: 2018/12/14 11:46:38; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: declerations.h,v
Working file: declerations.h
head: 1.8
branch:
locks: strict
root: 1.8
access list:
symbolic names:
keyword substitution: kv
total revisions: 8; selected revisions: 8
description:
Thius file would contain for all declerations in the Project.
declared mainMenu(), exitFunc(), compression(), deCompression()
----------------------------
revision 1.8 locked by: root;
date: 2018/12/20 11:27:30; author: root; state: Exp; lines: +16 -0
Replaces all function declerations and declared their function pointers
----------------------------
revision 1.7
date: 2018/12/20 11:09:16; author: root; state: Exp; lines: +7 -0
Declared all compressn()s.
All functions take the file descriptor of file to compress and the master Array as argument.
----------------------------
revision 1.6
date: 2018/12/20 11:00:42; author: root; state: Exp; lines: +1 -0
declader codeLength()
----------------------------
revision 1.5
date: 2018/12/14 11:44:38; author: root; state: Exp; lines: +1 -0
declared unique()
----------------------------
revision 1.4
date: 2018/12/14 11:34:38; author: root; state: Exp; lines: +1 -1
Updated decleration for creatMasterArray()
It now returns char*
----------------------------
revision 1.3
date: 2018/12/13 08:57:54; author: root; state: Exp; lines: +1 -0
declared createMasterArray()
----------------------------
revision 1.2
date: 2018/12/10 10:27:09; author: root; state: Exp; lines: +2 -1
declared openFile()
updates exitFunc()... passing the exit status as argument.
----------------------------
revision 1.1
date: 2018/12/10 09:59:30; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.2
branch:
locks: strict
root: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This file contains all included headers and Macros
included stdio.h and stdlib.h.
----------------------------
revision 1.2 locked by: root;
date: 2018/12/10 10:31:49; author: root; state: Exp; lines: +3 -0
included string.h, usistd.h and fcntl.h
----------------------------
revision 1.1
date: 2018/12/10 10:00:05; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress2.c,v
Working file: compress2.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function will provide compression when code length will be 2. Just checking mapping for now.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/20 11:10:01; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress3.c,v
Working file: compress3.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function will provide comcode length 3.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/20 11:10:39; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress4.c,v
Working file: compress4.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function will provide compression when code length will be 4.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/20 11:11:03; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress5.c,v
Working file: compress5.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function will provide compression when code length will be 5
----------------------------
revision 1.1 locked by: root;
date: 2018/12/20 11:11:27; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress6.c,v
Working file: compress6.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function will provide compression when code length will be 6
----------------------------
revision 1.1 locked by: root;
date: 2018/12/20 11:11:31; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress7.c,v
Working file: compress7.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function will provide compression when code length will be 7
----------------------------
revision 1.1 locked by: root;
date: 2018/12/20 11:11:35; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.7
branch:
locks: strict
root: 1.7
access list:
symbolic names:
keyword substitution: kv
total revisions: 7; selected revisions: 7
description:
This function would initiate the compression operation. Just checking mapping for now.
----------------------------
revision 1.7 locked by: root;
date: 2018/12/20 11:28:02; author: root; state: Exp; lines: +9 -9
all the function calls are now being done through function pointers.
----------------------------
revision 1.6
date: 2018/12/20 11:11:40; author: root; state: Exp; lines: +21 -0
Depending on the code length, we call appropriate compressn()s using switch statement.
The compressn()s take the file descriptor of the file to compress and masterarray as argument
----------------------------
revision 1.5
date: 2018/12/20 11:01:43; author: root; state: Exp; lines: +3 -1
determines codelength of the compressed codes.
calle codeLength() that takes ma as argument, return code length.
Print code length.
----------------------------
revision 1.4
date: 2018/12/14 11:35:03; author: root; state: Exp; lines: +3 -1
Captured thwe return value from creatMasterArray() and printed it.
----------------------------
revision 1.3
date: 2018/12/13 09:01:09; author: root; state: Exp; lines: +1 -0
Calling createMasterArray() and gived the opened file descriptor as arument.
This function should return the masterArray(). i.e. array of unique characters.
----------------------------
revision 1.2
date: 2018/12/10 10:28:07; author: root; state: Exp; lines: +4 -0
calling openFile() to open the file.
getting fd from this func and printing.
----------------------------
revision 1.1
date: 2018/12/10 10:01:36; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: createMasterArray.c,v
Working file: createMasterArray.c
head: 1.8
branch:
locks: strict
root: 1.8
access list:
symbolic names:
keyword substitution: kv
total revisions: 8; selected revisions: 8
description:
This function would create an array of unique characters from opened file and return it to the compresion()
----------------------------
revision 1.8 locked by: root;
date: 2018/12/20 11:28:27; author: root; state: Exp; lines: +1 -1
all the function calls are now being done through function pointers.
----------------------------
revision 1.7
date: 2018/12/20 10:53:31; author: root; state: Exp; lines: +9 -6
Changing the size of masterarray using realloc()
----------------------------
revision 1.6
date: 2018/12/14 11:44:49; author: root; state: Exp; lines: +2 -1
After reading the char from file, we call unique() to check if the char is unique/not found in masterarray.
Then only we store it in the masterarray.
This is done by calling unique() in the if()
unique() return 1 if char is unique else if the char is found in ther array it treturn 0
----------------------------
revision 1.5
date: 2018/12/14 11:35:34; author: root; state: Exp; lines: +2 -2
The created Master Array is returned.
The return type of function is updated acccordingly.
----------------------------
revision 1.4
date: 2018/12/13 09:10:01; author: root; state: Exp; lines: +1 -1
Storingend-of-file char one position bofore the end of file.
----------------------------
revision 1.3
date: 2018/12/13 09:08:55; author: root; state: Exp; lines: +1 -0
Appending the end-of-string to the masterarray.
----------------------------
revision 1.2
date: 2018/12/13 09:06:46; author: root; state: Exp; lines: +11 -2
Earlier we were printingthe chars read from file. Now, we would store the chars read from file into an array.
then after reading from file is over, we print the array.
----------------------------
revision 1.1
date: 2018/12/13 09:02:21; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: init.c,v
Working file: init.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function initializez all function pointers with function names.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/20 11:28:40; author: root; state: Exp;
Initial revision
=============================================================================
@page { margin: 0.79in }
pre.cjk { font-family: "DejaVu Sans Mono", monospace }
p { margin-bottom: 0.1in; line-height: 120% }
RCS file: main.c,v
Working file: main.c
head: 1.5
branch:
locks: strict
root: 1.5
access list:
symbolic names:
keyword substitution: kv
total revisions: 5; selected revisions: 5
description:
This is the Main Project Source File
Project: Multiple Data Compression and Encryption using Iterative Technique.
In an infinite loop, calling mainMenu() and getting the choice.
Depending on the choice, calling the appropriate function using switch.
----------------------------
revision 1.5 locked by: root;
date: 2018/12/20 11:30:20; author: root; state: Exp; lines: +1 -0
calling init() for func pr initialization.
----------------------------
revision 1.4
date: 2018/12/20 11:29:38; author: root; state: Exp; lines: +1 -1
typo
----------------------------
revision 1.3
date: 2018/12/20 11:29:02; author: root; state: Exp; lines: +4 -4
all the function calls are now being done through function pointers.
----------------------------
revision 1.2
date: 2018/12/10 10:29:16; author: root; state: Exp; lines: +1 -1
undated the exit() call, giving the exit status as argument
----------------------------
revision 1.1
date: 2018/12/10 10:03:45; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: mainMenu.c,v
Working file: mainMenu.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function would...
display main menu, get choice from user and return choice to main().
----------------------------
revision 1.1 locked by: root;
date: 2018/12/10 10:05:20; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: declaration.h,v
Working file: declaration.h
head: 1.5
branch:
locks: strict
jchaudhary: 1.5
access list:
symbolic names:
keyword substitution: kv
total revisions: 5; selected revisions: 5
description:
this file would contain for all declarations in the project
declared mainmenu(),exitfunction(), compression(),decompression()
----------------------------
revision 1.5 locked by: jchaudhary;
date: 2018/12/20 06:04:02; author: jchaudhary; state: Exp; lines: +1 -1
this h
this file would contain all the headers file
stdio.h string.h stdlib.h unistd.h fcntl.h
----------------------------
revision 1.4
date: 2018/12/17 06:53:49; author: jchaudhary; state: Exp; lines: +2 -1
added unique function
----------------------------
revision 1.3
date: 2018/12/14 10:06:25; author: jchaudhary; state: Exp; lines: +2 -2
*** empty log message ***
----------------------------
revision 1.2
date: 2018/12/14 09:49:07; author: jchaudhary; state: Exp; lines: +2 -1
changed return type of openfile function
add new function createmasterarray
----------------------------
revision 1.1
date: 2018/12/12 13:21:40; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this file contains all the included headers and macros
file list: stdio.h stdlib.h string.h unistd.h fcntl.h
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/11 16:06:23; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.2
branch:
locks: strict
jchaudhary: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
----------------------------
revision 1.2 locked by: jchaudhary;
date: 2018/12/20 06:56:05; author: jchaudhary; state: Exp; lines: +2 -1
this function will use to compress file
openfile function wil be cll to open the file to copress
and openfile will return fd
after that called to createmasterarray function and passed fd to this function
----------------------------
revision 1.1
date: 2018/12/17 07:14:17; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: createmasterarray.c,v
Working file: createmasterarray.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/17 07:14:33; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: decompression.c,v
Working file: decompression.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this file will be use to decompress the file
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 07:07:10; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: exitfunction.c,v
Working file: exitfunction.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will be use to exit from the code in both situation(EXIT_SUCCESS & EXIT_FAILURE)
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 07:07:48; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: length.c,v
Working file: length.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 07:11:19; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this is main function of code
in the main
a mainmenu function will be call in a while(1) loop
mainmenu is enter the choice
1 for compression
2 for decompression
0 for exit
mainmenu returns an int type value enter by the user
and then work according to user choice
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 07:11:31; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: mainmenu.c,v
Working file: mainmenu.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
thil function will be call from main and it wil display chioces to use
1 for compression
2 for decompressinon
0 for exit
and return an int value to main entered by the user choice
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 07:19:14; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: openfile.c,v
Working file: openfile.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will be use to open the file and will return fd
and ask to user to enter the file name
malloc to store file name
.
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 08:09:07; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: unique.c,v
Working file: unique.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/17 07:15:33; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: createMasterArray.c,v
Working file: createMasterArray.c
head: 1.1
branch:
locks: strict
taruna: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: taruna;
date: 2018/12/15 06:21:27; author: taruna; state: Exp;
Initial revision
=============================================================================
RCS file: deCompression.c,v
Working file: deCompression.c
head: 1.1
branch:
locks: strict
taruna: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function would initate deCompression() operation.
just checking for mapping now
----------------------------
revision 1.1 locked by: taruna;
date: 2018/12/10 11:29:20; author: taruna; state: Exp;
Initial revision
=============================================================================
RCS file: exitFunc.c,v
Working file: exitFunc.c
head: 1.2
branch:
locks: strict
taruna: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This function will be used for exiting the project.
Exiting for success using exit
----------------------------
revision 1.2 locked by: taruna;
date: 2018/12/15 06:21:29; author: taruna; state: Exp; lines: +3 -3
This function is used to exit program.
----------------------------
revision 1.1
date: 2018/12/10 11:30:02; author: taruna; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.1
branch:
locks: strict
taruna: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This is the main project sourse file
Project name: Multiple Data Comoression and Encryption Using Iterative Techniques
In an infinite loop, calling mainMenu() and getting the choice
Depending on the choice, calling the appropriate function using switch
----------------------------
revision 1.1 locked by: taruna;
date: 2018/12/10 11:30:58; author: taruna; state: Exp;
Initial revision
Exiting for success using exit
----------------------------
revision 1.2 locked by: taruna;
date: 2018/12/15 06:21:29; author: taruna; state: Exp; lines: +3 -3
This function is used to exit program.
----------------------------
revision 1.1
date: 2018/12/10 11:30:02; author: taruna; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.1
branch:
locks: strict
taruna: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This is the main project sourse file
Project name: Multiple Data Comoression and Encryption Using Iterative Techniques
In an infinite loop, calling mainMenu() and getting the choice
Depending on the choice, calling the appropriate function using switch
----------------------------
revision 1.1 locked by: taruna;
date: 2018/12/10 11:30:58; author: taruna; state: Exp;
Initial revision
=============================================================================
RCS file: mainMenu.c,v
Working file: mainMenu.c
head: 1.2
branch:
locks: strict
taruna: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This function would display main menu.
get choice from user and return user's choice to main menu
----------------------------
revision 1.2 locked by: taruna;
date: 2018/12/15 06:21:31; author: taruna; state: Exp; lines: +2 -2
This function is to take user's choice from user.
0: exit
1: compress
2: decompress
----------------------------
revision 1.1
date: 2018/12/10 11:33:24; author: taruna; state: Exp;
Initial revision
=============================================================================
RCS file: declarations.h,v
Working file: declarations.h
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
here we declare the prototype for every function
we declare the mainmenu(),exitFunc(),openfile(),compression(),decompression() functions
----------------------------
revision 1.1
date: 2018/12/20 09:08:35; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
we included the all required header files
we included the stdio.h.stdlib.h,fcntl.h,unistd.h,string.h
----------------------------
revision 1.1
date: 2018/12/20 09:11:56; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
Here we declare a pointer to enter the name of file to be opened
then we call the openfile function
----------------------------
revision 1.1
date: 2018/12/20 09:13:52; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: createmasterarray.c,v
Working file: createmasterarray.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
Here we will create a masterarray of unique characters in the opened file
first we will declare a char pointer to store all unique characters
we will read the opened file character by character with the help of file descriptor
then we will call unique function to check whether the character read is unique or not
if character is unique,then it is stored in master array
otherwise next character is read
we will store all unique characters in master array
this will return the char pointer
----------------------------
revision 1.1
date: 2018/12/20 09:16:27; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: decompression.c,v
Working file: decompression.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1
date: 2018/12/20 09:22:25; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: exitFunc.c,v
Working file: exitFunc.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
It will exit the code
----------------------------
revision 1.1
date: 2018/12/20 09:22:48; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This is the main function
It will have an infinite while loop
In the while loop,we will call the mainmenu function and we will provide the choice
Based on the choice given,it will call the appropriate function to perform the required task
----------------------------
revision 1.1
date: 2018/12/20 09:48:51; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: mainmenu.c,v
Working file: mainmenu.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
In this function,we will give the choice to perform the task
It will return the integer choice
----------------------------
revision 1.1
date: 2018/12/20 09:53:07; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: openfile.c,v
Working file: openfile.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function is used to open file to be compressed
It will take filename as argument
It will open the file to be compressed in read only mode and provide the file descriptor
It will return fd to compression func
----------------------------
revision 1.1
date: 2018/12/20 09:58:59; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: unique.c,v
Working file: unique.c
head: 1.1
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This func is used to check whether the character read is unique or not
This will use the for loop to compare character read with the character in masterarray
If character is already present in ma,then it will return 0 otherwise will store in ma.
----------------------------
revision 1.1
date: 2018/12/20 11:51:41; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: codelength.c,v
Working file: codelength.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This func takes the ma as argument.
Then we calculate the length of ma by using strlen.
Depending on length of ma,this func will return value to compress func.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/21 17:40:48; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress2.c,v
Working file: compress2.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: root;
date: 2018/12/21 17:43:17; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress3.c,v
Working file: compress3.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: root;
date: 2018/12/21 17:43:32; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress4.c,v
Working file: compress4.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: root;
date: 2018/12/21 17:43:48; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress5.c,v
Working file: compress5.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: root;
date: 2018/12/21 17:43:50; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress6.c,v
Working file: compress6.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: root;
date: 2018/12/21 17:43:53; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compress7.c,v
Working file: compress7.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: root;
date: 2018/12/21 17:43:54; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.2
branch:
locks: strict
root: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
Here we declare a pointer to enter the name of file to be opened
then we call the openfile function
----------------------------
revision 1.2 locked by: root;
date: 2018/12/21 17:43:56; author: root; state: Exp; lines: +24 -5
Here we call the codelength func.
Then depending on the codelength of ma,we will call the compressn() func by using switch which takes the codelength as argument.
----------------------------
revision 1.1
date: 2018/12/20 09:13:52; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: createmasterarray.c,v
Working file: createmasterarray.c
head: 1.2
branch:
locks: strict
root: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
Here we will create a masterarray of unique characters in the opened file
first we will declare a char pointer to store all unique characters
we will read the opened file character by character with the help of file descriptor
then we will call unique function to check whether the character read is unique or not
if character is unique,then it is stored in master array
otherwise next character is read
we will store all unique characters in master array
this will return the char pointer
----------------------------
revision 1.2 locked by: root;
date: 2018/12/21 17:46:40; author: root; state: Exp; lines: +17 -12
we replaced the malloc with realloc.
we called the unique func by using its func ptr.
----------------------------
revision 1.1
date: 2018/12/20 09:16:27; author: root; state: Exp;
Initial revision
==========
RCS file: init.c,v
Working file: init.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This func is used for mapping func ptr with the respective func.
----------------------------
revision 1.1 locked by: root;
date: 2018/12/21 17:48:18; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.2
branch:
locks: strict
root: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This is the main function
It will have an infinite while loop
In the while loop,we will call the mainmenu function and we will provide the choice
Based on the choice given,it will call the appropriate function to perform the required task
----------------------------
revision 1.2 locked by: root;
date: 2018/12/21 17:49:06; author: root; state: Exp; lines: +9 -4
First we replaced all funcs with func ptrs.
we call the init() func.
----------------------------
revision 1.1
date: 2018/12/20 09:48:51; author: root; state: Exp;
Initial revision
================================
RCS file: mainmenu.c,v
Working file: mainmenu.c
head: 1.2
branch:
locks: strict
root: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
In this function,we will give the choice to perform the task
It will return the integer choice
----------------------------
revision 1.2 locked by: root;
date: 2018/12/21 17:50:59; author: root; state: Exp; lines: +1 -1
*** empty log message ***
----------------------------
revision 1.1
date: 2018/12/20 09:53:07; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: openfile.c,v
Working file: openfile.c
head: 1.1
branch:
locks: strict
root: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
This function is used to open file to be compressed
It will take filename as argument
It will open the file to be compressed in read only mode and provide the file descriptor
It will return fd to compression func
----------------------------
revision 1.1 locked by: root;
date: 2018/12/20 09:58:59; author: root; state: Exp;
Initial revision
=============================================================================
RCS file: unique.c,v
Working file: unique.c
head: 1.2
branch:
locks: strict
root: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
This func is used to check whether the character read is unique or not
This will use the for loop to compare character read with the character in masterarray
If character is already present in ma,then it will return 0 otherwise will store in ma.
----------------------------
revision 1.2 locked by: root;
date: 2018/12/21 17:51:20; author: root; state: Exp; lines: +3 -6
*** empty log message ***
----------------------------
revision 1.1
date: 2018/12/20 11:51:41; author: root; state: Exp;
Initial revision
==================================
RCS file: declaration.h,v
Working file: declaration.h
head: 1.6
branch:
lyword substitution: kv
total revisions: 6; selected revisions: 6
description:
this file would contain for all declarations in the project
declared mainmenu(),exitfunction(), compression(),decompression()
----------------------------
revision 1.6 locked by: jchaudhary;
date: 2018/12/21 10:41:21; author: jchaudhary; state: Exp; lines: +37 -1
declared pointers to all the functions
----------------------------
revision 1.5
date: 2018/12/20 06:04:02; author: jchaudhary; state: Exp; lines: +1 -1
this h
this file would contain all the headers file
stdio.h string.h stdlib.h unistd.h fcntl.h
----------------------------
revision 1.4
date: 2018/12/17 06:53:49; author: jchaudhary; state: Exp; lines: +2 -1
added unique function
----------------------------
revision 1.3
date: 2018/12/14 10:06:25; author: jchaudhary; state: Exp; lines: +2 -2
*** empty log message ***
----------------------------
revision 1.2
date: 2018/12/14 09:49:07; author: jchaudhary; state: Exp; lines: +2 -1
changed return type of openfile function
add new function createmasterarray
----------------------------
revision 1.1
date: 2018/12/12 13:21:40; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: headers.h,v
Working file: headers.h
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this file contains all the included headers and macros
file list: stdio.h stdlib.h string.h unistd.h fcntl.h
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/11 16:06:23; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: compression2.c,v
Working file: compression2.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
openfile() createmasterarray() length(
replaced by pointers of functions
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/21 10:43:07; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: compression3.c,v
Working file: compression3.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will compress the targeted file when code length is less then 8
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/21 10:46:10; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: compression4.c,v
Working file: compression4.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will be you to compress target file when code length is less then 16
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/22 06:29:45; author: jchaudhary; state: Exp;
Initial revision
===================
Working file: compression5.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will compress the file when code length is less then 32
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/21 10:50:07; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: compression6.c,v
Working file: compression6.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will compress the file when code length is less then 64
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/21 10:51:15; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: compression7.c,v
Working file: compression7.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will compress the file when code length is less then 128
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/21 10:52:08; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: compression.c,v
Working file: compression.c
head: 1.2
branch:
locks: strict
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
----------------------------
revision 1.2
date: 2018/12/20 06:56:05; author: jchaudhary; state: Exp; lines: +2 -1
this function will use to compress file
openfile function wil be cll to open the file to copress
and openfile will return fd
after that called to createmasterarray function and passed fd to this function
----------------------------
revision 1.1
date: 2018/12/17 07:14:17; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: createmasterarray.c,v
Working file: createmasterarray.c
head: 1.3
branch:
locks: strict
jchaudhary: 1.3
access list:
symbolic names:
keyword substitution: kv
total revisions: 3; selected revisions: 3
description:
----------------------------
revision 1.3 locked by: jchaudhary;
date: 2018/12/21 10:54:50; author: jchaudhary; state: Exp; lines: +5 -5
malloc is replace by realloc
----------------------------
revision 1.2
date: 2018/12/21 06:24:06; author: jchaudhary; state: Exp; lines: +4 -1
memory allocation updated
melloc function replaced by realloc function
----------------------------
revision 1.1
date: 2018/12/17 07:14:33; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: decompression.c,v
Working file: decompression.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this file will be use to decompress the file
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 07:07:10; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: exitfunction.c,v
Working file: exitfunction.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will be use to exit from the code in both situation(EXIT_SUCCESS & EXIT_FAILURE)
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 07:07:48; author: jchaudhary; state: Exp;
Initial revision
===================================
RCS file: init.c,v
Working file: init.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function contains initilization of all the functions
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/21 10:56:07; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: length.c,v
Working file: length.c
head: 1.3
branch:
locks: strict
jchaudhary: 1.3
access list:
symbolic names:
keyword substitution: kv
total revisions: 3; selected revisions: 3
description:
----------------------------
revision 1.3 locked by: jchaudhary;
date: 2018/12/22 05:40:32; author: jchaudhary; state: Exp; lines: +23 -4
this function will count the code length or unique array and return an int value according to code length
----------------------------
revision 1.2
date: 2018/12/21 06:25:26; author: jchaudhary; state: Exp; lines: +1 -1
this function will use count to code length using strlen()
and return an int value according to code length
----------------------------
revision 1.1
date: 2018/12/20 07:11:19; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: main.c,v
Working file: main.c
head: 1.2
branch:
locks: strict
jchaudhary: 1.2
access list:
symbolic names:
keyword substitution: kv
total revisions: 2; selected revisions: 2
description:
this is main function of code
in the main
a mainmenu function will be call in a while(1) loop
mainmenu is enter the choice
1 for compression
2 for decompression
0 for exit
mainmenu returns an int type value enter by the user
and then work according to user choice
----------------------------
revision 1.2 locked by: jchaudhary;
date: 2018/12/22 05:45:11; author: jchaudhary; state: Exp; lines: +6 -5
replaced all the function by the function pointers
----------------------------
revision 1.1
date: 2018/12/20 07:11:31; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: mainmenu.c,v
Working file: mainmenu.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
thil function will be call from main and it wil display chioces to use
1 for compression
2 for decompressinon
0 for exit
and return an int value to main entered by the user choice
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 07:19:14; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: openfile.c,v
Working file: openfile.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
this function will be use to open the file and will return fd
and ask to user to enter the file name
malloc to store file name
.
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/20 08:09:07; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
RCS file: unique.c,v
Working file: unique.c
head: 1.1
branch:
locks: strict
jchaudhary: 1.1
access list:
symbolic names:
keyword substitution: kv
total revisions: 1; selected revisions: 1
description:
----------------------------
revision 1.1 locked by: jchaudhary;
date: 2018/12/17 07:15:33; author: jchaudhary; state: Exp;
Initial revision
=============================================================================
Why every character occupies 8-bit ?
Every character is represented using 8 bits because this bit configuration allows for the unique representation of all 128 characters in the ASCII standard code. While 8 bits can technically represent 256 combinations, but the ASCII code uses only 7 bits to represent its basic character set, from 0 to 127. The remaining 8th bit is commonly used for error checking as a parity bit.
Flip-flops are memory elements in digital circuits which is used to store binary information in two stable states: 0 and 1. They are used to store a single bit.
Threshold voltage is the minimum voltage required to bring a transistor into conducting state and allow the current flow through its terminal.
The forbidden region is a range of input voltages that keep a transistor in non-conducting state, thereby preventing current flow through its terminal.
It looks like you're new here. If you want to get involved, click one of these buttons!