-
Notifications
You must be signed in to change notification settings - Fork 130
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Some refactoring and renamings (#485)
* Location of some files was changes, crc and sha256 moved to client/algorithms, string_utils file * Linux compilation is fixed
- Loading branch information
Showing
55 changed files
with
344 additions
and
396 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#ifndef _CRC_H | ||
#define _CRC_H | ||
|
||
// header file of CRC-library | ||
|
||
#include <stdio.h> | ||
|
||
/* initialization of the internal CRC-table (with memory allocation) */ | ||
extern int crc_init(void); | ||
|
||
/* creation of the table in the external array of length of 256 double words */ | ||
extern int crc_makeTable(unsigned table[256]); | ||
|
||
/* добавить к накопленному CRC новые данные, содержащиеся в массиве buf | ||
длины len; возвращает новый CRC; начальное значение CRC=0 */ | ||
extern unsigned crc_addArray(unsigned char *buf, unsigned len, unsigned crc); | ||
|
||
/* добавить к накопленному CRC новые данные, содержащиеся в файле f, но не | ||
более len байт; возвращает новый CRC; начальное значение CRC=0 */ | ||
extern unsigned crc_addFile(FILE *f, unsigned len, unsigned crc); | ||
|
||
/* calculates CRC of the array */ | ||
#define crc_of_array(buf,len) crc_addArray(buf,len,0) | ||
|
||
/* calculates CRC of the file */ | ||
#define crc_of_file(f) crc_addFile(f,-1,0) | ||
|
||
#endif |
0
client/sha256-mb-x86_64-mac.s → client/algorithms/sha256-mb-x86_64-mac.s
100755 → 100644
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.