Esempio n. 1
0
extern int select_p_select_jobinfo_pack(select_jobinfo_t *jobinfo, Buf buffer,
					uint16_t protocol_version)
{
	int rc = SLURM_ERROR;

	_select_jobinfo_pack(jobinfo, buffer, protocol_version);
	if (jobinfo)
		rc = other_select_jobinfo_pack(jobinfo->other_jobinfo, buffer,
					       protocol_version);
	else
		rc = other_select_jobinfo_pack(NULL, buffer, protocol_version);
	return rc;
}
Esempio n. 2
0
extern int select_p_select_jobinfo_pack(select_jobinfo_t *jobinfo, Buf buffer,
					uint16_t protocol_version)
{
	int rc = SLURM_ERROR;

	if (protocol_version >= SLURM_2_2_PROTOCOL_VERSION) {
		if (!jobinfo) {
			pack32(0, buffer);
			return SLURM_SUCCESS;
		}
		pack32(jobinfo->reservation_id, buffer);
		rc = other_select_jobinfo_pack(jobinfo->other_jobinfo, buffer,
					       protocol_version);
	}
	return rc;
}
Esempio n. 3
0
extern int select_p_select_jobinfo_pack(select_jobinfo_t *jobinfo, Buf buffer,
					uint16_t protocol_version)
{
	int rc = SLURM_ERROR;

	if (protocol_version >= SLURM_MIN_PROTOCOL_VERSION) {
		if (!jobinfo) {
			pack8(0, buffer);
			pack32(0, buffer);
			pack64(0, buffer);
			return SLURM_SUCCESS;
		}
		pack8(jobinfo->confirmed, buffer);
		pack32(jobinfo->reservation_id, buffer);
		pack64(jobinfo->confirm_cookie, buffer);
		rc = other_select_jobinfo_pack(jobinfo->other_jobinfo, buffer,
					       protocol_version);
	} else {
 		error("select_p_select_jobinfo_pack: protocol_version "
 		      "%hu not supported", protocol_version);
	}
	return rc;
}