From: Matthew Fernandez Date: Sun, 5 Jul 2020 23:40:24 +0000 (-0700) Subject: remove unused vmset API X-Git-Tag: 2.46.0~20^2^2~193^2~3 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e7bfc6b74e207788e1be0358ccc8edbdc557ebb1;p=graphviz remove unused vmset API --- diff --git a/lib/vmalloc/CMakeLists.txt b/lib/vmalloc/CMakeLists.txt index 0b8734def..1fd463f49 100644 --- a/lib/vmalloc/CMakeLists.txt +++ b/lib/vmalloc/CMakeLists.txt @@ -12,7 +12,6 @@ add_library(vmalloc STATIC vmdcheap.c vmopen.c vmprivate.c - vmset.c vmstat.c vmstrdup.c vmwalk.c diff --git a/lib/vmalloc/Makefile.am b/lib/vmalloc/Makefile.am index 941ef6eb9..056500f63 100644 --- a/lib/vmalloc/Makefile.am +++ b/lib/vmalloc/Makefile.am @@ -6,7 +6,7 @@ noinst_LTLIBRARIES = libvmalloc_C.la libvmalloc_C_la_SOURCES = vmbest.c vmclear.c vmclose.c vmdcheap.c \ vmopen.c vmprivate.c \ - vmset.c vmstat.c vmstrdup.c \ + vmstat.c vmstrdup.c \ vmwalk.c EXTRA_DIST = README vmalloc.vcxproj* diff --git a/lib/vmalloc/vmalloc.h b/lib/vmalloc/vmalloc.h index dbd816ab2..181494a96 100644 --- a/lib/vmalloc/vmalloc.h +++ b/lib/vmalloc/vmalloc.h @@ -117,8 +117,6 @@ extern "C" { extern long vmaddr(Vmalloc_t *, void *); - extern int vmset(Vmalloc_t *, int, int); - extern void *vmdbwatch(void *); extern int vmdbcheck(Vmalloc_t *); diff --git a/lib/vmalloc/vmalloc.vcxproj b/lib/vmalloc/vmalloc.vcxproj index 8158a667d..3371f531b 100644 --- a/lib/vmalloc/vmalloc.vcxproj +++ b/lib/vmalloc/vmalloc.vcxproj @@ -102,7 +102,6 @@ - diff --git a/lib/vmalloc/vmalloc.vcxproj.filters b/lib/vmalloc/vmalloc.vcxproj.filters index 8fba3e301..8692a8a67 100644 --- a/lib/vmalloc/vmalloc.vcxproj.filters +++ b/lib/vmalloc/vmalloc.vcxproj.filters @@ -41,9 +41,6 @@ Source Files - - Source Files - Source Files diff --git a/lib/vmalloc/vmset.c b/lib/vmalloc/vmset.c deleted file mode 100644 index 9751a1636..000000000 --- a/lib/vmalloc/vmset.c +++ /dev/null @@ -1,53 +0,0 @@ -/* $Id$ $Revision$ */ -/* vim:set shiftwidth=4 ts=8: */ - -/************************************************************************* - * Copyright (c) 2011 AT&T Intellectual Property - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: See CVS logs. Details at http://www.graphviz.org/ - *************************************************************************/ - -#include "vmhdr.h" - - -/* Set the control flags for a region. -** -** Written by Kiem-Phong Vo, kpv@research.att.com, 01/16/94. -*/ -/** - * @param vm region being worked on - * @param flags flags must be in VM_FLAGS - * @param on !=0 if turning on, else turning off - */ -int vmset(reg Vmalloc_t * vm, int flags, int on) -{ - reg int mode; - reg Vmdata_t *vd = vm->data; - - if (flags == 0 && on == 0) - return vd->mode; - - if (!(vd->mode & VM_TRUST)) { - if (ISLOCK(vd, 0)) - return 0; - SETLOCK(vd, 0); - } - - mode = vd->mode; - - if (on) - vd->mode |= (flags & VM_FLAGS); - else - vd->mode &= ~(flags & VM_FLAGS); - - if (vd->mode & (VM_TRACE | VM_MTDEBUG)) - vd->mode &= ~VM_TRUST; - - CLRLOCK(vd, 0); - - return mode; -}