summaryrefslogtreecommitdiff
path: root/noncore/settings/aqpkg/datamgr.cpp
Unidiff
Diffstat (limited to 'noncore/settings/aqpkg/datamgr.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/aqpkg/datamgr.cpp45
1 files changed, 7 insertions, 38 deletions
diff --git a/noncore/settings/aqpkg/datamgr.cpp b/noncore/settings/aqpkg/datamgr.cpp
index bb86766..7c49621 100644
--- a/noncore/settings/aqpkg/datamgr.cpp
+++ b/noncore/settings/aqpkg/datamgr.cpp
@@ -88,3 +88,3 @@ void DataManager :: loadServers()
88 lineStr = line; 88 lineStr = line;
89 if ( lineStr.startsWith( "src" ) || lineStr.startsWith( "#src" ) || lineStr.startsWith( "# src" ) ) 89 if ( lineStr.startsWith( "src" ) ) //|| lineStr.startsWith( "#src" ) || lineStr.startsWith( "# src" ) )
90 { 90 {
@@ -100,6 +100,9 @@ void DataManager :: loadServers()
100 Server s( alias, url ); 100 Server s( alias, url );
101 if ( lineStr.startsWith( "src" ) )
102 s.setActive( true );
103 else
104 s.setActive( false );
105
101 serverList.push_back( s ); 106 serverList.push_back( s );
102 107
103 if ( lineStr.startsWith( "src" ) )
104 setActiveServer( alias );
105 } 108 }
@@ -117,36 +120,2 @@ void DataManager :: loadServers()
117 120
118 // Go through the server destination list and add root, cf and card if they
119 // don't already exist
120/* AQ - commented out as if you don't have a CF or SD card in then
121 * this causes IPKG to try to create directories on non existant devices
122 * (which of course fails), gives a nasty error message and can cause ipkg
123 * to seg fault.
124 *
125 vector<Destination>::iterator dit;
126 bool foundRoot = false;
127 bool foundCF = false;
128 bool foundCard = false;
129 for ( dit = destList.begin() ; dit != destList.end() ; ++dit )
130 {
131 if ( dit->getDestinationPath() == "/" )
132 foundRoot = true;
133 if ( dit->getDestinationPath() == "/mnt/cf" )
134 foundCF = true;
135 if ( dit->getDestinationPath() == "/mnt/card" )
136 foundCard = true;
137 }
138
139 // If running on a Zaurus (arm) then if we didn't find root, CF or card
140 // destinations, add them as default
141#ifdef QWS
142#ifndef X86
143 if ( !foundRoot )
144 destList.push_back( Destination( "root", "/" ) );
145 if ( !foundCF )
146 destList.push_back( Destination( "cf", "/mnt/cf" ) );
147 if ( !foundCF )
148 destList.push_back( Destination( "card", "/mnt/card" ) );
149#endif
150#endif
151*/
152 vector<Server>::iterator it; 121 vector<Server>::iterator it;
@@ -203,3 +172,3 @@ void DataManager :: writeOutIpkgConf()
203 172
204 if ( !activeServer || alias != activeServer ) 173 if ( !it->isServerActive() )
205 out << "#"; 174 out << "#";