~ubuntu-branches/debian/jessie/smstools/jessie

« back to all changes in this revision

Viewing changes to src/locking.c

  • Committer: Bazaar Package Importer
  • Author(s): Jan Wagner
  • Date: 2010-06-21 10:19:52 UTC
  • mfrom: (1.1.11 upstream)
  • Revision ID: james.westby@ubuntu.com-20100621101952-pz5h5zctan8vumbi
Tags: 3.1.10-0.1
* Non-maintainer upload, as requested by maintainer
* New Upstream version (Closes: #586643)
* Bump Standards to 3.8.4, no changes needed
* Define source format 1.0 in debian/source/format
* Add $remote_fs as dependency for Required-Start and Required-Stop in the
  init script, removed $local_fs, which is implicit

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
 
32
32
  if (!filename)
33
33
    return 0;
34
 
  if (strlen(filename) >= sizeof(lockfilename))
 
34
  if (strlen(filename) + 5 >= sizeof(lockfilename))
35
35
    return 0;
36
36
 
37
37
  strcpy(lockfilename,filename);
57
57
 
58
58
  if (!filename)
59
59
    return 0;
60
 
  if (strlen(filename) >= sizeof(lockfilename))
 
60
  if (strlen(filename) + 5 >= sizeof(lockfilename))
61
61
    return 0;
62
62
 
63
63
  strcpy(lockfilename,filename);
73
73
 
74
74
  if (!filename)
75
75
    return 0;
76
 
  if (strlen(filename) >= sizeof(lockfilename))
 
76
  if (strlen(filename) + 5 >= sizeof(lockfilename))
77
77
    return 0;
78
78
 
79
79
  strcpy(lockfilename,filename);