summaryrefslogtreecommitdiff
path: root/src/intersim2/networks
diff options
context:
space:
mode:
authorAhmad Alawneh <[email protected]>2023-06-12 17:31:05 -0400
committerGitHub <[email protected]>2023-06-12 17:31:05 -0400
commitb471b3481b2399222ffd9ee0f007628834e68767 (patch)
tree267f112f3608ce7f4caa898250a3eb24a90814b6 /src/intersim2/networks
parent73db3f79467cb918c6ac11796268e2492c69b101 (diff)
fixing bunch of formatting warnings (#53)
* fixing bunch of formating warrnings * remove unintialized and unused results warnnings * revert the changes , as it doenst fix the warning --------- Co-authored-by: Fangjia Shen <[email protected]>
Diffstat (limited to 'src/intersim2/networks')
-rw-r--r--src/intersim2/networks/kncube.cpp2
-rw-r--r--src/intersim2/networks/qtree.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/intersim2/networks/kncube.cpp b/src/intersim2/networks/kncube.cpp
index 03e13e7..178c905 100644
--- a/src/intersim2/networks/kncube.cpp
+++ b/src/intersim2/networks/kncube.cpp
@@ -231,7 +231,7 @@ void KNCube::InsertRandomFaults( const Configuration &config )
int num_fails;
unsigned long prev_seed;
- int node, chan;
+ int node, chan = 0;
int i, j, t, n, c;
bool available;
diff --git a/src/intersim2/networks/qtree.cpp b/src/intersim2/networks/qtree.cpp
index 7214947..37d3d7c 100644
--- a/src/intersim2/networks/qtree.cpp
+++ b/src/intersim2/networks/qtree.cpp
@@ -84,7 +84,7 @@ void QTree::_BuildNet( const Configuration& config )
{
ostringstream routerName;
- int h, r, pos, port;
+ int h, r = 0 , pos, port;
for (h = 0; h < _n; h++) {
for (pos = 0 ; pos < powi( _k, h ) ; ++pos ) {