summaryrefslogtreecommitdiff
path: root/source3/lib/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/lib/util.c')
-rw-r--r--source3/lib/util.c27
1 files changed, 8 insertions, 19 deletions
diff --git a/source3/lib/util.c b/source3/lib/util.c
index 13f5b17781..b4d9e9f16f 100644
--- a/source3/lib/util.c
+++ b/source3/lib/util.c
@@ -249,7 +249,13 @@ BOOL init_names(void)
int n;
if (global_myname() == NULL || *global_myname() == '\0') {
- if (!set_global_myname(myhostname())) {
+ fstring name;
+
+ fstrcpy( name, myhostname() );
+ p = strchr( name, '.' );
+ if (p)
+ *p = 0;
+ if (!set_global_myname(name)) {
DEBUG( 0, ( "init_structs: malloc fail.\n" ) );
return False;
}
@@ -1008,7 +1014,7 @@ BOOL get_myfullname(char *my_name)
Get my own domain name.
****************************************************************************/
-BOOL get_mydomname(fstring my_domname)
+BOOL get_mydomname(char *my_domname)
{
pstring hostname;
char *p;
@@ -1724,23 +1730,6 @@ BOOL is_myname_or_ipaddr(const char *s)
}
/*******************************************************************
- Is the name specified our workgroup/domain.
- Returns true if it is equal, false otherwise.
-********************************************************************/
-
-BOOL is_myworkgroup(const char *s)
-{
- BOOL ret = False;
-
- if (strequal(s, lp_workgroup())) {
- ret=True;
- }
-
- DEBUG(8, ("is_myworkgroup(\"%s\") returns %d\n", s, ret));
- return(ret);
-}
-
-/*******************************************************************
Set the horrid remote_arch string based on an enum.
********************************************************************/