Skip to content

Instantly share code, notes, and snippets.

@tuxillo
tuxillo / 0001-Add-missing-cast-to-double.patch
Created January 14, 2017 10:44
Add missing cast to double
From fcc2307568fe2a92bef6783f0937bc34552f28a2 Mon Sep 17 00:00:00 2001
From: Antonio Huete Jimenez <tuxillo@quantumachine.net>
Date: Sat, 14 Jan 2017 00:16:43 +0000
Subject: Add missing cast to double
---
src/commands/CmdBurndown.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/commands/CmdBurndown.cpp b/src/commands/CmdBurndown.cpp
@tuxillo
tuxillo / 0001-Add-missing-cast-to-double.patch
Created January 14, 2017 00:24
Attempt to fix build in SunOS-like environments.
From fcc2307568fe2a92bef6783f0937bc34552f28a2 Mon Sep 17 00:00:00 2001
From: Antonio Huete Jimenez <tuxillo@quantumachine.net>
Date: Sat, 14 Jan 2017 00:16:43 +0000
Subject: [PATCH 1/2] Add missing cast to double
---
src/commands/CmdBurndown.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/commands/CmdBurndown.cpp b/src/commands/CmdBurndown.cpp
@tuxillo
tuxillo / 0001-Attempt-to-fix-build-in-SunOS-like-environments.patch
Created January 13, 2017 23:31
[PATCH] Attempt to fix build in SunOS-like environments.
From c269b75d94efdfeb15beaea338416a7c3624ec46 Mon Sep 17 00:00:00 2001
From: Antonio Huete Jimenez <tuxillo@quantumachine.net>
Date: Mon, 9 Jan 2017 19:54:58 +0000
Subject: [PATCH] Attempt to fix build in SunOS-like environments.
---
CMakeLists.txt | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/CMakeLists.txt b/CMakeLists.txt
diff --git a/usr.sbin/installer/libinstaller/survey.c b/usr.sbin/installer/libinstaller/survey.c
index 42b5a28..3dad695 100644
--- a/usr.sbin/installer/libinstaller/survey.c
+++ b/usr.sbin/installer/libinstaller/survey.c
@@ -199,11 +199,23 @@ survey_storage(struct i_fn_args *a)
command_set_log_mode(cmd, COMMAND_LOG_SILENT);
aura_dict_rewind(di);
- while (!aura_dict_eof(di)) {
- aura_dict_get_current_key(di, &rk, &rk_len),
91419: sysinfo(SI_ISALIST, "amd64 pentium_pro+mmx pentium_pro pentium+mmx pentium i486 i386 i86", 255) = 68
91419: access("/opt/pkgsrc/devel/nbpatch/work/.tools/bin/amd64/sort", X_OK) Err#2 ENOENT
91419: access("/opt/pkgsrc/devel/nbpatch/work/.tools/bin/pentium_pro+mmx/sort", X_OK) Err#2 ENOENT
91419: access("/opt/pkgsrc/devel/nbpatch/work/.tools/bin/pentium_pro/sort", X_OK) Err#2 ENOENT
91419: access("/opt/pkgsrc/devel/nbpatch/work/.tools/bin/pentium+mmx/sort", X_OK) Err#2 ENOENT
91419: access("/opt/pkgsrc/devel/nbpatch/work/.tools/bin/pentium/sort", X_OK) Err#2 ENOENT
91419: access("/opt/pkgsrc/devel/nbpatch/work/.tools/bin/i486/sort", X_OK) Err#2 ENOENT
91419: access("/opt/pkgsrc/devel/nbpatch/work/.tools/bin/i386/sort", X_OK) Err#2 ENOENT
91419: access("/opt/pkgsrc/devel/nbpatch/work/.tools/bin/i86/sort", X_OK) Err#2 ENOENT
91419: fstat64(2, 0x08046820) = 0
/*
* Copyright (c) 2015 The DragonFly Project. All rights reserved.
*
* This code is derived from software contributed to The DragonFly Project
* by Matthew Dillon <dillon@backplane.com>
* by Antonio Huete Jimenez <tuxillo@quantumachine.net>
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
diff --git a/sbin/hammer/cmd_dedup.c b/sbin/hammer/cmd_dedup.c
index 5b4d43d..288020f 100644
--- a/sbin/hammer/cmd_dedup.c
+++ b/sbin/hammer/cmd_dedup.c
@@ -101,6 +101,7 @@ struct pass2_dedup_entry {
#define DEDUP_PASS2 0x0001 /* process_btree_elm() mode */
static int SigInfoFlag;
+static int SigAlrmFlag;
static int64_t DedupDataReads;
diff --git a/sbin/hammer/cmd_dedup.c b/sbin/hammer/cmd_dedup.c
index 5b4d43d..e307e58 100644
--- a/sbin/hammer/cmd_dedup.c
+++ b/sbin/hammer/cmd_dedup.c
@@ -101,6 +101,7 @@ struct pass2_dedup_entry {
#define DEDUP_PASS2 0x0001 /* process_btree_elm() mode */
static int SigInfoFlag;
+static int SigAlarmFlag;
static int64_t DedupDataReads;
diff --git a/sys/platform/vkernel64/platform/init.c b/sys/platform/vkernel64/platform/init.c
index 8183e24..5d1ea92 100644
--- a/sys/platform/vkernel64/platform/init.c
+++ b/sys/platform/vkernel64/platform/init.c
@@ -143,6 +143,9 @@ static int unix_connect(const char *path);
static void usage_err(const char *ctl, ...);
static void usage_help(_Bool);
static void init_locks(void);
+static void handle_term(int);
+
diff --git a/sbin/disklabel64/disklabel64.c b/sbin/disklabel64/disklabel64.c
index afd77ec..05d4747 100644
--- a/sbin/disklabel64/disklabel64.c
+++ b/sbin/disklabel64/disklabel64.c
@@ -119,8 +119,11 @@ extern uint32_t crc32(const void *buf, size_t size);
#define BIG_NEWFS_FRAG 2048U
#define BIG_NEWFS_CPG 64U
+#define PARTOFF(p) (parts[p-1].dp_start * 512LU)
+