Example #1
0
static void specify_envlist( struct work_queue_task *t, struct jx *envlist )
{
	if(envlist) {
		struct jx_pair *p;
		for(p=envlist->u.pairs;p;p=p->next) {
			work_queue_task_specify_enviroment_variable(t,p->key->u.string_value,p->value->u.string_value);
		}
	}
}
static void specify_envlist( struct work_queue_task *t, struct nvpair *envlist )
{
	if(envlist) {
		char *name, *value;
		nvpair_first_item(envlist);
		while(nvpair_next_item(envlist,&name,&value)) {
			work_queue_task_specify_enviroment_variable(t,name,value);
		}
	}
}
Example #3
0
static void specify_integer_env_var( struct work_queue_process *p, const char *name, int64_t value) {
	char *value_str = string_format("%" PRId64, value);
	work_queue_task_specify_enviroment_variable(p->task, name, value_str);
	free(value_str);
}