Skip to content

Commit

Permalink
Two minor compilation fixes
Browse files Browse the repository at this point in the history
(g++ version 7.3.0 / Ubuntu 18.04.1 LTS)
  • Loading branch information
gi0e5b06 committed Oct 14, 2018
1 parent 7d993dd commit 1e7b9c2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/synth/constants.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define OXFM_PATCH_VERSION 5
#define VERSION_STR "1.3.6"
#define VERSION_INT ((OXFM_MAJOR_VERSION * 100) + (OXFM_MINOR_VERSION * 10) + OXFM_PATCH_VERSION)
#define TITLE_SMALL "Oxe FM Synth "VERSION_STR
#define TITLE_FULL TITLE_SMALL" :: http://www.oxesoft.com"
#define TITLE_SMALL "Oxe FM Synth " VERSION_STR
#define TITLE_FULL TITLE_SMALL " :: http://www.oxesoft.com"
#define SAMPLES_PER_PROCESS 128 // the synth process buffer size
#define WAVEFORM_BIT_DEPTH 11
#define WAVEFORM_BSIZE (1<<WAVEFORM_BIT_DEPTH) // waveform size
Expand Down
6 changes: 3 additions & 3 deletions src/toolkits/embedresources.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ void append_file(FILE *fout, const char *path, const char *name)
FILE *f = fopen(path, "rb");
unsigned char c;
unsigned int i = 0;
fprintf(fout, "const char _%s[] = {\n", name);
fprintf(fout, "const unsigned char _%s[] = {\n", name);
while (!feof(f))
{
fread(&c, 1, 1, f);
(void)fread(&c, 1, 1, f);
fprintf(fout, "0x%02X%s%s", c, !feof(f) ? "," : "", ++i % 16 ? "" : "\n");
}
fprintf(fout, "};\n");
fprintf(fout, "const char *%s = _%s;\n", name, name);
fprintf(fout, "const char *%s = (const char *)_%s;\n", name, name);
fclose(f);
}

Expand Down
2 changes: 1 addition & 1 deletion src/toolkits/xlibtoolkit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ void GetResourcesPath(char *path, int size)
strncpy(path, info.dli_fname, PATH_MAX);
char* tmp = strrchr(path, '/');
*tmp = 0;
strcat(path, "/"BMP_PATH"/");
strcat(path, "/" BMP_PATH "/");
}

CXlibToolkit::CXlibToolkit(void *parentWindow, CEditor *editor)
Expand Down

0 comments on commit 1e7b9c2

Please sign in to comment.