[llvm-commits] [llvm-gcc-4.2] r129966 - /llvm-gcc-4.2/trunk/gcc/config/darwin.c
Eric Christopher
echristo at apple.com
Thu Apr 21 18:10:14 PDT 2011
Author: echristo
Date: Thu Apr 21 20:10:13 2011
New Revision: 129966
URL: http://llvm.org/viewvc/llvm-project?rev=129966&view=rev
Log:
Fix an off by one error in my previous patch.
Modified:
llvm-gcc-4.2/trunk/gcc/config/darwin.c
Modified: llvm-gcc-4.2/trunk/gcc/config/darwin.c
URL: http://llvm.org/viewvc/llvm-project/llvm-gcc-4.2/trunk/gcc/config/darwin.c?rev=129966&r1=129965&r2=129966&view=diff
==============================================================================
--- llvm-gcc-4.2/trunk/gcc/config/darwin.c (original)
+++ llvm-gcc-4.2/trunk/gcc/config/darwin.c Thu Apr 21 20:10:13 2011
@@ -2813,7 +2813,7 @@
strncpy(*new_triple + base_len + strlen ("ios"),
darwin_iphoneos_version_min,
strlen(darwin_iphoneos_version_min));
- (*new_triple)[base_len+os_len+1] = '\0';
+ (*new_triple)[base_len+os_len] = '\0';
return 1;
} else if ((isOSX || isDarwin) && darwin_macosx_version_min) {
/* llvm-gcc doesn't support pre-10.0 macosx systems. */
@@ -2826,7 +2826,7 @@
strncpy(*new_triple + base_len + strlen("macosx"),
darwin_macosx_version_min,
strlen(darwin_macosx_version_min));
- (*new_triple)[base_len+os_len+1] = '\0';
+ (*new_triple)[base_len+os_len] = '\0';
return 1;
}
More information about the llvm-commits
mailing list