~ubuntu-branches/ubuntu/intrepid/samba/intrepid-updates

« back to all changes in this revision

Viewing changes to source/smbd/sesssetup.c

  • Committer: Bazaar Package Importer
  • Author(s): Chuck Short
  • Date: 2008-06-02 09:01:46 UTC
  • mfrom: (0.25.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20080602090146-92ur4nx39ccg708r
Tags: 2:3.0.30-2ubuntu1
* Merge from debian unstable, remaining changes:
  * debian/patches/VERSION.patch
    - set SAMABA_VERSION_VENDOR_SUFFIX to Ubuntu
  * debian/smb.conf
    - add "(Samba, Ubuntu)" to server string.
    - comment out the default [homes] shares, and a comment about
      "value users = %S to show users how to restrict access to 
      \\server\useranem to only username.
    - Add map to guest = Bad user, maps bad username to guest access.
      (LP: #32067)
  * debian/samba-common.postinst:
    - Fix upgrade from a first installation done with feisty, edgy, or dapper.
      (LP: #201059)
    - When populating the new sambashare group, it's not an error if the user
      simply doesn't exist; test for this case and the install continue 
      instead of aborting. (LP: #206036)
  * debian/smba-common.config:
    - do not change priority to HIGH if dhclient3 is installed
    - used priority medium instead of hight for the workgroup question
  * debian/winbind.files
    - insclude additional files
  * debian/patches/fix-documentation.patch:
    - fix typos in net(8) and smb.conf(5) man pages
  * debian/mksambapasswd.awk:
    - Don't add user with UID less than 1000 to smbpasswd.
  * debian/samba.init:
    - add 'status' option for LSB conformance.
  * Updated control version.
  * Dropped Changes:
    - Dropped debian/patches/fix-smbprinting-os2.patch. Accepted upstream.
    - Dropped debian/patches/fix-documentation.patch. Accepted upstream.
     

Show diffs side-by-side

added added

removed removed

Lines of Context:
1184
1184
static int shutdown_other_smbds(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf,
1185
1185
                                void *p)
1186
1186
{
1187
 
        struct sessionid *sessionid = (struct sessionid *)dbuf.dptr;
 
1187
        struct sessionid sessionid;
1188
1188
        const char *ip = (const char *)p;
1189
1189
 
1190
 
        if (!process_exists(pid_to_procid(sessionid->pid))) {
1191
 
                return 0;
1192
 
        }
1193
 
 
1194
 
        if (sessionid->pid == sys_getpid()) {
1195
 
                return 0;
1196
 
        }
1197
 
 
1198
 
        if (strcmp(ip, sessionid->ip_addr) != 0) {
1199
 
                return 0;
1200
 
        }
1201
 
 
1202
 
        message_send_pid(pid_to_procid(sessionid->pid), MSG_SHUTDOWN,
 
1190
        SMB_ASSERT(dbuf.dsize == sizeof(sessionid));
 
1191
        memcpy(&sessionid, dbuf.dptr, sizeof(sessionid));
 
1192
 
 
1193
        if (!process_exists(pid_to_procid(sessionid.pid))) {
 
1194
                return 0;
 
1195
        }
 
1196
 
 
1197
        if (sessionid.pid == sys_getpid()) {
 
1198
                return 0;
 
1199
        }
 
1200
 
 
1201
        if (strcmp(ip, sessionid.ip_addr) != 0) {
 
1202
                return 0;
 
1203
        }
 
1204
 
 
1205
        message_send_pid(pid_to_procid(sessionid.pid), MSG_SHUTDOWN,
1203
1206
                         NULL, 0, True);
1204
1207
        return 0;
1205
1208
}