Ticket #1761: detect_lc_dvd.diff

File detect_lc_dvd.diff, 958 bytes (added by lists@…, 18 years ago)

Detect DVD using lowercase dir names

  • mythcdrom.cpp

     
    1616#ifndef PATHTO_DVD_DETECT
    1717#define PATHTO_DVD_DETECT "/VIDEO_TS"
    1818#endif
     19#ifndef PATHTO_DVD_LC_DETECT
     20#define PATHTO_DVD_LC_DETECT "/video_ts"
     21#endif
    1922
    2023#ifndef PATHTO_VCD_DETECT
    2124#define PATHTO_VCD_DETECT "/vcd"
     
    7477    DetectPath.sprintf("%s%s", (const char*)m_MountPath, PATHTO_DVD_DETECT);
    7578    VERBOSE(VB_IMPORTANT, QString("Looking for: '%1'").arg(DetectPath));
    7679
     80    DetectPath2.sprintf("%s%s", (const char*)m_MountPath, PATHTO_DVD_LC_DETECT);
     81    VERBOSE(VB_IMPORTANT, QString("Looking for: '%1'").arg(DetectPath2));
     82
    7783    struct stat sbuf;
    78     if (stat(DetectPath, &sbuf) == 0)
     84    if (stat(DetectPath, &sbuf) == 0 || stat(DetectPath2, &sbuf) == 0)
    7985    {
    8086        VERBOSE(VB_GENERAL, "Probable DVD detected.");
    8187        m_MediaType = MEDIATYPE_DVD;