Important Update:

- Implement Handle Address renaming:
- Restructure JSON config, with address list and rename list
- SelectableCore:
  - Add method GetHandleAddress() - lookup renamed handle
  - Add init values to all struct and classes declarations
- Replace malloc()/strcpy() sequences with strdup()
This commit is contained in:
Charl Wentzel
2019-01-08 08:35:21 +02:00
parent c5da842ac1
commit 3e40f7a86d
7 changed files with 128 additions and 232 deletions

View File

@@ -80,10 +80,8 @@ TFileHandle * CFileCore::AddFile( const char * Name, const char * Path, bool Ap
*FileHandle = (TFileHandle*)calloc( 1, sizeof(TFileHandle) );
// Set name & Path
(*FileHandle)->Name = (char*)malloc( strlen(Name)+1 );
strcpy( (*FileHandle)->Name, Name );
(*FileHandle)->Path = (char*)malloc( strlen(Path)+1 );
strcpy( (*FileHandle)->Path, Path );
(*FileHandle)->Name = strdup( Name );
(*FileHandle)->Path = strdup( Path );
}
// Create Channel if necessary