~ubuntu-branches/debian/experimental/apt/experimental

« back to all changes in this revision

Viewing changes to apt-pkg/deb/debsrcrecords.h

  • Committer: Bazaar Package Importer
  • Author(s): Michael Vogt
  • Date: 2010-02-18 22:07:23 UTC
  • mfrom: (9.1.7 sid)
  • Revision ID: james.westby@ubuntu.com-20100218220723-zb7zdh6fmsmp30tr
Tags: 0.7.26~exp2
fix crash when LANGUAGE is not set

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
 
15
15
#include <apt-pkg/srcrecords.h>
16
16
#include <apt-pkg/tagfile.h>
17
 
#include <apt-pkg/contrib/fileutl.h>
 
17
#include <apt-pkg/fileutl.h>
18
18
 
19
19
class debSrcRecordParser : public pkgSrcRecords::Parser
20
20
{
30
30
 
31
31
   virtual bool Restart() {return Tags.Jump(Sect,0);};
32
32
   virtual bool Step() {iOffset = Tags.Offset(); return Tags.Step(Sect);};
33
 
   virtual bool Jump(unsigned long Off) {iOffset = Off; return Tags.Jump(Sect,Off);};
 
33
   virtual bool Jump(unsigned long const &Off) {iOffset = Off; return Tags.Jump(Sect,Off);};
34
34
 
35
35
   virtual string Package() const {return Sect.FindS("Package");};
36
36
   virtual string Version() const {return Sect.FindS("Version");};
37
37
   virtual string Maintainer() const {return Sect.FindS("Maintainer");};
38
38
   virtual string Section() const {return Sect.FindS("Section");};
39
39
   virtual const char **Binaries();
40
 
   virtual bool BuildDepends(vector<BuildDepRec> &BuildDeps, bool ArchOnly);
 
40
   virtual bool BuildDepends(vector<BuildDepRec> &BuildDeps, bool const &ArchOnly, bool const &StripMultiArch = true);
41
41
   virtual unsigned long Offset() {return iOffset;};
42
42
   virtual string AsStr() 
43
43
   {
47
47
   };
48
48
   virtual bool Files(vector<pkgSrcRecords::File> &F);
49
49
 
50
 
   debSrcRecordParser(string File,pkgIndexFile const *Index) 
 
50
   debSrcRecordParser(string const &File,pkgIndexFile const *Index) 
51
51
      : Parser(Index), Fd(File,FileFd::ReadOnly), Tags(&Fd,102400), 
52
52
        Buffer(0), BufSize(0) {}
 
53
   ~debSrcRecordParser();
53
54
};
54
55
 
55
56
#endif