Project

General

Profile

Bug #1894 ยป mode-666.patch

Bodo Eggert, 2013-12-31 16:22

View differences:

src/muxer/muxer_pass.c
376 376
  int fd;
377 377
  pass_muxer_t *pm = (pass_muxer_t*)m;
378 378

  
379
  fd = open(filename, O_WRONLY | O_CREAT | O_TRUNC, 0777);
379
  fd = open(filename, O_WRONLY | O_CREAT | O_TRUNC, 0666);
380 380
  if(fd < 0) {
381 381
    pm->pm_error = errno;
382 382
    tvhlog(LOG_ERR, "pass", "%s: Unable to create file, open failed -- %s",
src/muxer/tvh/mkmux.c
1041 1041
{
1042 1042
  int fd;
1043 1043

  
1044
  fd = open(filename, O_WRONLY | O_CREAT | O_TRUNC, 0777);
1044
  fd = open(filename, O_WRONLY | O_CREAT | O_TRUNC, 0666);
1045 1045
  if(fd < 0) {
1046 1046
    mkm->error = errno;
1047 1047
    tvhlog(LOG_ERR, "mkv", "%s: Unable to create file, open failed -- %s",
src/settings.c
161 161

  
162 162
  /* Create tmp file */
163 163
  snprintf(tmppath, sizeof(tmppath), "%s.tmp", path);
164
  if((fd = tvh_open(tmppath, O_CREAT | O_TRUNC | O_RDWR, 0700)) < 0) {
164
  if((fd = tvh_open(tmppath, O_CREAT | O_TRUNC | O_RDWR, 0666)) < 0) {
165 165
    tvhlog(LOG_ALERT, "settings", "Unable to create \"%s\" - %s",
166 166
	    tmppath, strerror(errno));
167 167
    return;
......
367 367
  /* Open file */
368 368
  int flags = for_write ? O_CREAT | O_TRUNC | O_WRONLY : O_RDONLY;
369 369

  
370
  return tvh_open(path, flags, 0700);
370
  return tvh_open(path, flags, 0666);
371 371
}
    (1-1/1)