Skip to content

Commit

Permalink
tiny problems in libsim
Browse files Browse the repository at this point in the history
  • Loading branch information
gitgjogh committed Jan 6, 2016
1 parent 3d1f071 commit 2c5b5ca
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion libsim/sim_log.c
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ int slogv(slog_t *sl, int level, const char *prompt, const char *fmt, va_list ap

int xlogv(int level, const char *prompt, const char *fmt, va_list ap)
{
slogv(&g_slog_obj, level, prompt, fmt, ap);
return slogv(&g_slog_obj, level, prompt, fmt, ap);
}

int slog (slog_t *sl, int level, const char *prompt, const char *fmt, ...)
Expand Down
8 changes: 7 additions & 1 deletion libsim/sim_opt.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
#include <limits.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>

#include "sim_opt.h"

Expand Down Expand Up @@ -368,7 +369,12 @@ int ref_ival_2_idx(int nref, const opt_ref_t *refs, int val)
{
int i;
char s[256] = {0};
snprintf(s, 256, "%d", val);

#ifdef WIN32
_snprintf(s, 256, "%d", val);
#else
snprintf(s, 256, "%d", val);
#endif
return ref_sval_2_idx(nref, refs, s);
}

Expand Down
1 change: 1 addition & 0 deletions libsim/sim_utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

#include <limits.h>
#include <string.h>
#include <ctype.h>
#include <math.h>

#include "sim_utils.h"
Expand Down

0 comments on commit 2c5b5ca

Please sign in to comment.