]> git.proxmox.com Git - mirror_qemu.git/blobdiff - bsd-user/freebsd/os-syscall.c
bsd-user: Implement trunctate and ftruncate
[mirror_qemu.git] / bsd-user / freebsd / os-syscall.c
index d9ebb9d50d681ba6ce5cdab3962dec73cde25d81..3c8f6cad0e84cab4918acfcb4e3147bcbb68ceac 100644 (file)
@@ -357,6 +357,14 @@ static abi_long freebsd_syscall(void *cpu_env, int num, abi_long arg1,
         ret = do_bsd_dup2(arg1, arg2);
         break;
 
+    case TARGET_FREEBSD_NR_truncate: /* truncate(2) */
+        ret = do_bsd_truncate(cpu_env, arg1, arg2, arg3, arg4);
+        break;
+
+    case TARGET_FREEBSD_NR_ftruncate: /* ftruncate(2) */
+        ret = do_bsd_ftruncate(cpu_env, arg1, arg2, arg3, arg4);
+        break;
+
     default:
         qemu_log_mask(LOG_UNIMP, "Unsupported syscall: %d\n", num);
         ret = -TARGET_ENOSYS;