Minor changes to lv_api_do.c

This commit is contained in:
Jesse Gardner 2021-04-25 09:48:08 -07:00
parent 1f3335e7b3
commit 09880ae7fe
2 changed files with 2 additions and 4 deletions

BIN
lv_api_do

Binary file not shown.

View File

@ -1,7 +1,7 @@
#include <libvirt.h>
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include <libvirt/libvirt.h>
void pr_bad(); void pr_bad();
void pr_conn_bad(); void pr_conn_bad();
@ -48,9 +48,7 @@ const char NOMATCH[]="# No matching domain";
int main () { int main () {
setlinebuf(stdout); /* Make sure output is always line buffered */ setlinebuf(stdout); /* Make sure output is always line buffered */
/* Connect to libvirt API */ conn=virConnectOpen(NULL); /* Connect to libvirt API */
conn=virConnectOpen(NULL);
int loop=1;
if ( conn == NULL) { if ( conn == NULL) {
pr_conn_bad(); pr_conn_bad();
exit(E_LIBVIRT); exit(E_LIBVIRT);