Skip to content

Commit 28785d1

Browse files
committed
HACK PATH_MAX msvc x64 fixes
1 parent 000b1e1 commit 28785d1

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/libavrdude.h

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -872,7 +872,11 @@ typedef struct { // Memory cache for a subset of cached pages
872872
#define OFF 0 // Many contexts: reset, power, LEDs, ...
873873
#define ON 1 // Many contexts
874874

875+
#ifdef PATH_MAX
875876
#define PGM_PORTLEN PATH_MAX
877+
#else
878+
#define PGM_PORTLEN _MAX_PATH
879+
#endif
876880
#define PGM_TYPELEN 32
877881

878882
typedef enum {
@@ -1528,8 +1532,8 @@ void terminal_setup_update_progress(void);
15281532
extern "C" {
15291533
#endif
15301534

1531-
void win_sys_config_set(char sys_config[PATH_MAX]);
1532-
void win_usr_config_set(char usr_config[PATH_MAX]);
1535+
void win_sys_config_set(char *sys_config);
1536+
void win_usr_config_set(char *usr_config);
15331537

15341538
#ifdef __cplusplus
15351539
}

0 commit comments

Comments
 (0)