Exemple #1
0
int main(int argc, char** argv){

        if (argc != 2){
                printf("ERROR!\n Incorrect INPUT data\n It mast look ./m <dir>\n");
                exit(-1);
        }

        char *r_path = realpath(argv[1], NULL);
        if (r_path == NULL)
        {
                printf("realpath failed\n");
                free(r_path);
                exit(-1);
        }

        int nid;
        nid = fork();
        if (nid < 0)
                my_error("Can't fork!\n");
        else
                if( nid  == 0)
                        call_1(r_path);
                else
                        call_2();
        return 0;
}
Exemple #2
0
			SPROUT_CONSTEXPR result_type call(
				typename Expr::args_type const& args,
				context_type const& ctx
				) const
			{
				return call_1(args, ctx, sprout::weed::eval(sprout::tuples::get<0>(args), ctx));
			}
Exemple #3
0
			SPROUT_CONSTEXPR typename std::enable_if<
				(sizeof...(Attrs) + 2 < limit::value),
				result_type
			>::type call(
				expr1_type const& expr1,
				expr2_type const& expr2,
				context_type const& ctx,
				sprout::weed::limited::category limited_category,
				Result const& res,
				Head const& head,
				Attrs const&... attrs
				) const
			{
				return res.success()
					? call_1(
						expr1,
						expr2,
						res.ctx(),
						limited_category,
						sprout::weed::eval(expr2, res.ctx()),
						head,
						attrs...,
						res.attr()
						)
					: result_type(
						true,
						ctx.begin(),
						sprout::weed::attr_cnv::modulus<limit::value, attr_type>(head, attrs...),
						ctx
						)
					;
			}
Exemple #4
0
 BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
 static Result
 call(State const& state,It0 const& it0,F f)
 {
     return call_1(
         f(state,it0),
         fusion::next(it0),
         f);
 }
Exemple #5
0
 BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
 static Result
 call(State const& state,It0 const& it0,F f)
 {
     return call_1(
                f(state,BOOST_FUSION_FOLD_IMPL_INVOKE_IT_TRANSFORM(it0)),
                fusion::BOOST_FUSION_FOLD_IMPL_NEXT_IT_FUNCTION(it0),
                f);
 }
Exemple #6
0
			SPROUT_CONSTEXPR typename std::enable_if<
				!Infinity,
				result_type
			>::type call(
				expr1_type const& expr1,
				expr2_type const& expr2,
				context_type const& ctx,
				Result const& res
				) const
			{
				return res.success()
					? call_1(
						expr1,
						expr2,
						res.ctx(),
						sprout::tuples::get<0>(expr1.args()).limited_category(),
						sprout::weed::eval(expr2, res.ctx()), res.attr()
						)
					: result_type(false, ctx.begin(), attribute_type(), ctx)
					;
			}
Exemple #7
0
int call_1(int n)
{
	if (n==0)
		return 0;
	return call_1(n/10)+1;
}
Exemple #8
0
int main(void)
{
	printf("%d\n", call_1(123));
	return 0;
}