/* * $Id$ * 'OpenSSL for Ruby' project * Copyright (C) 2001-2003 Michal Rokos * All rights reserved. */ /* * This program is licenced under the same licence as Ruby. * (See the file 'LICENCE'.) */ #if !defined(_OSSL_RUBY_MISSING_H_) #define _OSSL_RUBY_MISSING_H_ #define rb_define_copy_func(klass, func) \ rb_define_method(klass, "initialize_copy", func, 1) #ifndef GetReadFile #define FPTR_TO_FD(fptr) (fptr->fd) #else #define FPTR_TO_FD(fptr) (fileno(GetReadFile(fptr))) #endif #ifndef HAVE_RB_IO_T #define rb_io_t OpenFile #endif #ifndef HAVE_RB_STR_SET_LEN /* these methods should probably be backported to 1.8 */ #define rb_str_set_len(str, length) do { \ RSTRING(str)->ptr[length] = 0; \ RSTRING(str)->len = length; \ } while(0) #endif /* ! HAVE_RB_STR_SET_LEN */ #ifndef HAVE_RB_BLOCK_CALL /* the openssl module doesn't use arg[3-4] and arg2 is always rb_each */ #define rb_block_call(arg1, arg2, arg3, arg4, arg5, arg6) rb_iterate(rb_each, arg1, arg5, arg6) #endif /* ! HAVE_RB_BLOCK_CALL */ #endif /* _OSSL_RUBY_MISSING_H_ */ anoopcs/public_git/glusterfs.git/'>glusterfs.git
GlusterFS is a distributed file-system capable of scaling to several petabytes. It aggregates various storage bricks over Infiniband RDMA or TCP/IP interconnect into one large parallel network file system.Anoop C S
summaryrefslogtreecommitdiffstats
path: root/tests/fallocate.rc
blob: 3756bb949bd94c576b00c81b0acdb3e6d00c7d4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/bin/bash

# Helper to verify a given fallocate command is supported and skip a test
# otherwise. Older versions of the fallocate utility might not support all modes
# (i.e., discard) and older versions of fuse might not support the associated
# fallocate requests.

function require_fallocate()
{
	output=`fallocate $* 2>&1`
	ret=$?
	if [ ! $ret -eq 0 ] && ([[ $output == *unsupported* ]] ||
				[[ $output == *invalid* ]] ||
				[[ $output == *"not supported"* ]])
	then
		SKIP_TESTS
		exit
	fi
}