static int read_tls_directory(RBuffer *b, ut64 addr, PE_(image_tls_directory) *tls_directory) {
	st64 o_addr = r_buf_seek (b, 0, R_BUF_CUR);
	if (r_buf_seek (b, addr, R_BUF_SET) < 0) {
		return -1;
	}
	tls_directory->StartAddressOfRawData = r_buf_read_le32 (b);
	tls_directory->EndAddressOfRawData = r_buf_read_le32 (b);
	tls_directory->AddressOfIndex = r_buf_read_le32 (b);
	tls_directory->AddressOfCallBacks = r_buf_read_le32 (b);
	tls_directory->SizeOfZeroFill = r_buf_read_le32 (b);
	tls_directory->Characteristics = r_buf_read_le32 (b);
	r_buf_seek (b, o_addr, R_BUF_SET);
	return sizeof (PE_(image_tls_directory));
}
static int read_tls_directory(RBuffer *b, ut64 addr, PE_(image_tls_directory) *tls_directory) {
	st64 o_addr = r_buf_seek (b, 0, R_BUF_CUR);
	if (r_buf_seek (b, addr, R_BUF_SET) < 0) {
		return -1;
	}
	tls_directory->StartAddressOfRawData = r_buf_read_le32 (b);
	tls_directory->EndAddressOfRawData = r_buf_read_le32 (b);
	tls_directory->AddressOfIndex = r_buf_read_le32 (b);
	tls_directory->AddressOfCallBacks = r_buf_read_le32 (b);
	tls_directory->SizeOfZeroFill = r_buf_read_le32 (b);
	tls_directory->Characteristics = r_buf_read_le32 (b);
	r_buf_seek (b, o_addr, R_BUF_SET);
	return sizeof (PE_(image_tls_directory));
}