~ubuntu-branches/ubuntu/jaunty/clamav/jaunty-backports

« back to all changes in this revision

Viewing changes to shared/output.c

  • Committer: Bazaar Package Importer
  • Author(s): Scott Kitterman
  • Date: 2010-10-02 15:36:00 UTC
  • mfrom: (10.1.6 sid)
  • mto: This revision was merged to the branch mainline in revision 13.
  • Revision ID: james.westby@ubuntu.com-20101002153600-2tx3vki1u55cdrjy
Tags: 0.96.3+dfsg-2ubuntu0.10.04.1
Microversion update to 0.96.3 for Lucid (LP: #653738)

Show diffs side-by-side

added added

removed removed

Lines of Context:
297
297
                memset(&fl, 0, sizeof(fl));
298
298
                fl.l_type = F_WRLCK;
299
299
                if(fcntl(fileno(logg_fp), F_SETLK, &fl) == -1) {
 
300
#ifdef EOPNOTSUPP
 
301
                    if(errno == EOPNOTSUPP)
 
302
                        printf("WARNING: File locking not supported (NFS?)\n");
 
303
                    else
 
304
#endif
 
305
                    {
300
306
#ifdef CL_THREAD_SAFE
301
 
                    pthread_mutex_unlock(&logg_mutex);
 
307
                        pthread_mutex_unlock(&logg_mutex);
302
308
#endif
303
 
                    printf("ERROR: %s is locked by another process\n", logg_file);
304
 
                    if(len > sizeof(buffer))
305
 
                        free(abuffer);
306
 
                    return -1;
307
 
                }
 
309
                        printf("ERROR: %s is locked by another process\n", logg_file);
 
310
                        if(len > sizeof(buffer))
 
311
                            free(abuffer);
 
312
                        return -1;
 
313
                    }
 
314
                }
308
315
            }
309
316
#endif
310
317
        }