proxy_services.c revision aec5785126354bd8b192f63fe04ea08dae9c0705
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder Stephen Gallagher <sgallagh@redhat.com>
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder Copyright (C) 2012 Red Hat
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder This program is free software; you can redistribute it and/or modify
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder it under the terms of the GNU General Public License as published by
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder the Free Software Foundation; either version 3 of the License, or
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder (at your option) any later version.
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder This program is distributed in the hope that it will be useful,
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder but WITHOUT ANY WARRANTY; without even the implied warranty of
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder GNU General Public License for more details.
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder You should have received a copy of the GNU General Public License
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder along with this program. If not, see <http://www.gnu.org/licenses/>.
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder cased_name = sss_get_cased_name(tmp_ctx, svc->s_name, !lowercase);
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder protocols = talloc_array(tmp_ctx, const char *, 2);
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder protocols[0] = sss_get_cased_name(protocols, svc->s_proto,
8b8548df458142254941ca61bbc1e7177f7c7c08Simon Ulbricht /* Count the aliases */
8b8548df458142254941ca61bbc1e7177f7c7c08Simon Ulbricht for(num_aliases = 0; svc->s_aliases[num_aliases]; num_aliases++);
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder cased_aliases = talloc_array(tmp_ctx, const char *, num_aliases + 1);
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder for (i = 0; i < num_aliases; i++) {
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder cased_aliases[i] = sss_get_cased_name(tmp_ctx, svc->s_aliases[i],
158e6d8b5f7ebabef2d020ff045ede18fab15ff9Christian Maeder result = talloc_zero(tmp_ctx, struct servent);
goto done;
return ret;
done:
return ret;
const char *be_filter,
const char *protocol)
if (!result) {
goto done;
errno = 0;
if (errno) {
goto done;
return ret;
done:
return ret;