Index: libvdpau-0.4.1/src/vdpau_wrapper.c =================================================================== --- libvdpau-0.4.1/src/vdpau_wrapper.c +++ libvdpau-0.4.1/src/vdpau_wrapper.c 2012-07-05 19:59:16.211821996 +0300 @@ -322,6 +322,39 @@ if (strstr(buffer, "libflashplayer") != NULL) { _running_under_flash = 1; + return; + } + + fp = fopen("/proc/self/comm", "r"); + if (!fp) { + return; + } + ret = fread(buffer, 1, sizeof(buffer) - 1, fp); + fclose(fp); + buffer[ret] = '\0'; + + if (strncmp(buffer, "opera:libflashp", 15) == 0) { + _running_under_flash = 1; + return; + } + + /* konqueror */ + if (strncmp(buffer, "nspluginviewer", 14) == 0) { + char *line = NULL; + size_t buflen = 0; + + fp = fopen("/proc/self/maps", "r"); + if (!fp) { + return; + } + + while ((ret = getline(&line, &buflen, fp)) >= 0) { + if (ret >= 18 && strncmp(line + ret - 18, "libflashplayer.so", 17) == 0) { + _running_under_flash = 1; + break; + } + } + fclose(fp); } }