Navigation Menu

Skip to content

Commit

Permalink
Fix compilation for 32bit machines
Browse files Browse the repository at this point in the history
%Ld works for size_t only on 64 bit, the correct conversion is %zd
  • Loading branch information
karlp authored and Hakkavélin committed Nov 1, 2011
1 parent ee77215 commit e8bae67
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gdbserver/gdb-server.c
Expand Up @@ -143,7 +143,7 @@ int parse_options(int argc, char** argv, st_state_t *st) {
break;
case 'd':
if (strlen(optarg) > sizeof (st->devicename)) {
fprintf(stderr, "device name too long: %ld\n", strlen(optarg));
fprintf(stderr, "device name too long: %zd\n", strlen(optarg));
} else {
strcpy(st->devicename, optarg);
}
Expand Down

0 comments on commit e8bae67

Please sign in to comment.