[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] printf()'s in virsh?



Hi guys,

In virsh, in the cmdSchedinfo() function, there's a block of code using printf instead of vshPrintf():

  for (i = 0; i < nparams; i++){
      switch (params[i].type) {
      case VIR_DOMAIN_SCHED_FIELD_INT:
           printf("%-15s: %d\n",  params[i].field, params[i].value.i);
           break;
      case VIR_DOMAIN_SCHED_FIELD_UINT:
           printf("%-15s: %u\n",  params[i].field, params[i].value.ui);
           break;
      case VIR_DOMAIN_SCHED_FIELD_LLONG:
           printf("%-15s: %lld\n",  params[i].field, params[i].value.l);
           break;
      case VIR_DOMAIN_SCHED_FIELD_ULLONG:
           printf("%-15s: %llu\n",  params[i].field, params[i].value.ul);
           break;
      case VIR_DOMAIN_SCHED_FIELD_DOUBLE:
           printf("%-15s: %f\n",  params[i].field, params[i].value.d);
           break;
      case VIR_DOMAIN_SCHED_FIELD_BOOLEAN:
           printf("%-15s: %d\n",  params[i].field, params[i].value.b);
           break;
      default:
           printf("not implemented scheduler parameter type\n");
      }
  }

These should be vshPrintf() shouldn't they?

Regards and best wishes,

Justin Clift

--
Salasaga  -  Open Source eLearning IDE
              http://www.salasaga.org


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]