[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#679065: texlive-binaries: opening to/from pipes broken



Package: texlive-binaries
Version: 2012.20120623-1
Severity: important

Following a thread on the TL mailing list, the following
document breaks:
\documentclass{article}
\makeatletter
\@@input"|kpsewhich -var-value=max_print_line"\relax
\makeatother
\begin{document}
\end{document}

Possible fixes are:
* replace all occurrences of "rb" and "wb" as arguments to runpopen
  in texmfmp.c with "r" and "w", respectively
  The "b" variants are for Windows only, for which we do not compile

* add a #if defined(WIN32)
      *f_ptr = runpopen(fname+1,"rb");
  #else
      *f_ptr = runpopen(fname+1,"r");
  #endif
  etc around the three occurrences

* add something like
+  string realmode = xmalloc(strlen(mode)+2);
+  strcpy(realmode, mode);
 #ifdef WIN32
+  strcat(realmode, "b");
+
 this patch to the runpopen function, and also replace all the "rb" "wb"


Norbert



Reply to: