Skip to content

Commit 08da9ce

Browse files
alfredfothesamesam
authored andcommitted
[libc] Fix argument types for {f,}truncate specs
The current argument types are currently switched around for ftruncate and truncate. Currently passes tests because the internal definitions inside the __llvm_libc namespace are fine. Reviewed By: michaelrj, thesamesam, sivachandra Differential Revision: https://reviews.llvm.org/D152664
1 parent 9c053e6 commit 08da9ce

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

libc/spec/posix.td

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,7 @@ def POSIX : StandardSpec<"POSIX"> {
425425
FunctionSpec<
426426
"ftruncate",
427427
RetValSpec<IntType>,
428-
[ArgSpec<ConstCharPtr>, ArgSpec<OffTType>]
428+
[ArgSpec<IntType>, ArgSpec<OffTType>]
429429
>,
430430
FunctionSpec<
431431
"geteuid",
@@ -580,7 +580,7 @@ def POSIX : StandardSpec<"POSIX"> {
580580
FunctionSpec<
581581
"truncate",
582582
RetValSpec<IntType>,
583-
[ArgSpec<IntType>, ArgSpec<OffTType>]
583+
[ArgSpec<ConstCharPtr>, ArgSpec<OffTType>]
584584
>,
585585
FunctionSpec<
586586
"unlink",

0 commit comments

Comments
 (0)