comparison agent/src/os/bsd/libproc_impl.c @ 8058:2394a89e89f4

8008088: SA can hang the VM Reviewed-by: mgronlun, sla, dholmes
author rbackman
date Wed, 13 Feb 2013 09:46:19 +0100
parents f08d439fab8c
children 39432a1cefdd
comparison
equal deleted inserted replaced
8057:7adae9244bc8 8058:2394a89e89f4
1 /* 1 /*
2 * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 2003, 2013, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
89 vfprintf(stderr, format, alist); 89 vfprintf(stderr, format, alist);
90 va_end(alist); 90 va_end(alist);
91 } 91 }
92 } 92 }
93 93
94 void print_error(const char* format,...) {
95 va_list alist;
96 va_start(alist, format);
97 fputs("ERROR: ", stderr);
98 vfprintf(stderr, format, alist);
99 va_end(alist);
100 }
101
94 bool is_debug() { 102 bool is_debug() {
95 return _libsaproc_debug; 103 return _libsaproc_debug;
96 } 104 }
97 105
98 // initialize libproc 106 // initialize libproc